1
0
forked from VimPlug/jedi

Fix sys.path completions, #1298

This commit is contained in:
Dave Halter
2019-03-13 21:11:20 +01:00
parent b659b20d27
commit 92a8a84ff2
2 changed files with 7 additions and 1 deletions

View File

@@ -99,7 +99,7 @@ def check_sys_path_modifications(module_context):
def get_sys_path_powers(names):
for name in names:
power = name.parent.parent
if power.type in ('power', 'atom_expr'):
if power is not None and power.type in ('power', 'atom_expr'):
c = power.children
if c[0].type == 'name' and c[0].value == 'sys' \
and c[1].type == 'trailer':