       return if target.length is 0
       @keyUsed = false
       @selectItemView(target)
-      callback(target.data('result-item'))
+      callback(@items[parseInt(target[0].dataset.index)])
   
     @parentView.on 'core:confirm', (e) =>
       target = @getSelectedItemView()

    @keyUsed = false

  setItems: (items=[]) ->
    if items.length is 0 then @setResultsNotAvailable() else @setResultsAvailable()
    @resultList.append _.map(items, (item) -> item.generateView())

  clearItems: ->
    @setResultsNotAvailable()

      return if not (@keyUsed or @parentView.inputView.isSamePreviousSearch()) 
      return if not target.hasClass('selected')
      @keyUsed = false
      callback(@items[parseInt(target[0].dataset.index)])

  setResultsNotAvailable: ->
    @resultList.addClass('hidden')
