summaryrefslogtreecommitdiff
path: root/cmd2.py
diff options
context:
space:
mode:
Diffstat (limited to 'cmd2.py')
-rwxr-xr-xcmd2.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/cmd2.py b/cmd2.py
index 4f077b35..1c2daf7b 100755
--- a/cmd2.py
+++ b/cmd2.py
@@ -1590,7 +1590,8 @@ class Cmd(cmd.Cmd):
# Remove any command names which are explicitly excluded from the help menu
for name in self.exclude_from_help:
- names.remove(name)
+ if name in names:
+ names.remove(name)
cmds_doc = []
cmds_undoc = []