From a534a58477f760ff7ed2795ab62c213bd96eebaa Mon Sep 17 00:00:00 2001 From: Strahinja Val Markovic Date: Mon, 14 Oct 2013 12:32:18 -0700 Subject: [PATCH] Checking if ultisnips data present before using it Mentioned in issue #583, but it's not the root cause. --- python/ycm/completers/general/ultisnips_completer.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python/ycm/completers/general/ultisnips_completer.py b/python/ycm/completers/general/ultisnips_completer.py index 7a364f4d..ca7b666e 100644 --- a/python/ycm/completers/general/ultisnips_completer.py +++ b/python/ycm/completers/general/ultisnips_completer.py @@ -45,7 +45,7 @@ class UltiSnipsCompleter( GeneralCompleter ): def OnBufferVisit( self, request_data ): - raw_candidates = request_data[ 'ultisnips_snippets' ] + raw_candidates = request_data.get( 'ultisnips_snippets', [] ) self._candidates = [ responses.BuildCompletionData( str( snip[ 'trigger' ] ),