 
   addValueToShadowInput: (currentText, dataId) ->
     @input.val('')
-    return if @shadowInput.val().includes("#{dataId}") if @shadowInput.val() # cast dataId to string before check
-    @currentData = {name: currentText, value: dataId}
+
+    if @attribute.multiple
+      return if @shadowInput.val().includes("#{dataId}") if @shadowInput.val() # cast dataId to string before check
+      @currentData = {name: currentText, value: dataId}
+    else
+      @currentData = {name: currentText, value: dataId}
+      return if @shadowInput.val().includes("#{dataId}") if @shadowInput.val() # cast dataId to string before check
+
     @shadowInput.append($('<option/>').attr('selected', true).attr('value', @currentData.value).text(@currentData.name))
     @onShadowChange()
 

class App.SearchableSelect extends Spine.Controller

  events:
    'input .js-input':                      'onInput'
    'blur .js-input':                       'onBlur'
    'focus .js-input':                      'onFocus'
    'focus .js-shadow':                     'onShadowFocus'
    'change .js-shadow':                    'onShadowChange'
    'click .js-option':                     'selectItem'
    'click .searchableSelect-option-text':  'selectItem'
    'click .searchableSelect-option-arrow': 'navigateIn'
    'click .js-back':                       'navigateOut'
    'mouseenter .js-option':                'highlightItem'
    'mouseenter .js-enter':                 'highlightItem'
    'mouseenter .js-back':                  'highlightItem'
    'shown.bs.dropdown':                    'onDropdownShown'
    'hidden.bs.dropdown':                   'onDropdownHidden'
    'keyup .js-input':                      'onKeyUp'
    'click .js-remove':                     'removeThisToken'

  elements:
    '.js-dropdown':               'dropdown'


  navigateIn: (event) ->
    event.stopPropagation()
    if !@attribute.multiple
      @selectItem(event)
    @navigateDepth(1)

  navigateOut: (event) ->
