diff options
author | Todd Leonhardt <todd.leonhardt@gmail.com> | 2019-03-18 22:47:24 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-03-18 22:47:24 -0400 |
commit | 57dd827963491439e40eb5dfe20811c14ea757ff (patch) | |
tree | 9503d37d813a83a4c991d8ff8b2ed92e4a97e4ce /examples/hooks.py | |
parent | 83a28727d012ab067d18d89d3b1ce6410459f67b (diff) | |
parent | 4523bc6a9fc36ff879b6767dcd23923aa40c4c47 (diff) | |
download | cmd2-git-57dd827963491439e40eb5dfe20811c14ea757ff.tar.gz |
Merge pull request #648 from python-cmd2/attributes
Converted class attributes to instance attributes
Diffstat (limited to 'examples/hooks.py')
-rwxr-xr-x | examples/hooks.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/hooks.py b/examples/hooks.py index b6f6263e..dd21e58a 100755 --- a/examples/hooks.py +++ b/examples/hooks.py @@ -87,7 +87,7 @@ class CmdLineApp(cmd2.Cmd): func = self.cmd_func(data.statement.command) if func is None: # check if the entered command might be an abbreviation - possible_cmds = [cmd for cmd in self.keywords if cmd.startswith(data.statement.command)] + possible_cmds = [cmd for cmd in self.get_all_commands() if cmd.startswith(data.statement.command)] if len(possible_cmds) == 1: raw = data.statement.raw.replace(data.statement.command, possible_cmds[0], 1) data.statement = self.statement_parser.parse(raw) |