   open: (cid, updateHistory) ->
     addClass @overlay, 'choco-show'
     addClass document.body, 'choco-body'
-    getEnv() if not env.shift < 1
+    getEnv() if env.shift is 0
     @updateDimensions()
     @select cid, updateHistory
     @


      addImage @, object, image

    list = @thumbnails.children
    n = list.length
    that = @
    handleClick = (n) -> addHandler list[n], 'click', -> that.select n

    handleClick i for i in [0..n-1]
    @





  select: (item, updateHistory = true) ->

    if typeof item is 'number'
      item = @storage.get item

