 
     atom.commands.add @vue.$el,
       'core:move-up': (event) =>
-        @vue.selected -= 1
+        if(@vue.selected > 0)
+          @vue.selected -= 1
         event.stopPropagation()
 
       'core:move-down': (event) =>
-        @vue.selected += 1
+        if(@vue.selected < maxSymbols - 1)
+          @vue.selected += 1
         event.stopPropagation()
 
       'core:confirm': (event) =>

SymbolSearchVue = require('../views/public-symbol-search-vue')

module.exports = class PublicSymbolSearch
  constructor: (@client) ->
    @vue = new SymbolSearchVue
    @element = document.createElement('div')

      req =
        typehint: "PublicSymbolSearchReq"
        keywords: newText.split(' ')
        maxResults: maxSymbols

      @client.post(req, (msg) =>
          @vue.results = msg.syms
