echoerr replaced by postvim message

This commit is contained in:
Chiel92 2013-06-08 10:16:22 +02:00
parent a6424c22d8
commit 1f91c59938

View File

@ -58,8 +58,7 @@ class CsharpCompleter( ThreadedCompleter ):
js = self.getResponse( '/autocomplete', parameters ) js = self.getResponse( '/autocomplete', parameters )
if(js != ''): if(js != ''):
completions = json.loads( js ) return json.loads( js )
return completions
return [] return []
def getResponse( self, endPoint, parameters={} ): def getResponse( self, endPoint, parameters={} ):
@ -70,5 +69,5 @@ class CsharpCompleter( ThreadedCompleter ):
response = urllib2.urlopen( target, parameters ) response = urllib2.urlopen( target, parameters )
return response.read() return response.read()
except: except:
vim.command( "echoerr 'Could not connect to " + target + "'" ) vimsupport.PostVimMessage( "Could not connect to " + target )
return '' return ''