diff options
author | Kevin Van Brunt <kmvanbrunt@gmail.com> | 2018-03-15 14:43:52 -0400 |
---|---|---|
committer | Kevin Van Brunt <kmvanbrunt@gmail.com> | 2018-03-15 14:43:52 -0400 |
commit | 2329eede4c3e54ac2b669106bd1c3c4cf8043019 (patch) | |
tree | de43683d0f75ed86e7e0140afaf8add867692a49 /cmd2.py | |
parent | 18da5f35486fce4009a8b12cb245cfe06f2b0e7f (diff) | |
download | cmd2-git-2329eede4c3e54ac2b669106bd1c3c4cf8043019.tar.gz |
Fixed indentation
Diffstat (limited to 'cmd2.py')
-rwxr-xr-x | cmd2.py | 16 |
1 files changed, 8 insertions, 8 deletions
@@ -1378,14 +1378,14 @@ class Cmd(cmd.Cmd): except AttributeError: compfunc = self.completedefault - # If there are subcommands, then try completing those if the cursor is in - # the token at index 1, otherwise default to using compfunc - subcommands = self.get_subcommands(command) - if subcommands is not None: - index_dict = {1: subcommands} - compfunc = functools.partial(index_based_complete, - index_dict=index_dict, - all_else=compfunc) + # If there are subcommands, then try completing those if the cursor is in + # the token at index 1, otherwise default to using compfunc + subcommands = self.get_subcommands(command) + if subcommands is not None: + index_dict = {1: subcommands} + compfunc = functools.partial(index_based_complete, + index_dict=index_dict, + all_else=compfunc) # Call the completer function self.completion_matches = compfunc(text, line, begidx, endidx) |