battleman: fixed 'print' command on a group, cleaned up and added some output

This commit is contained in:
2012-04-06 02:04:04 -04:00
parent 9c6ac3056b
commit 4c6f96832b
2 changed files with 8 additions and 7 deletions

View File

@ -122,9 +122,9 @@ class CommandParser(Cmd):
if num_cmds == 1:
return getattr(self, 'do_'+cmds[0])(data)
elif num_cmds > 1:
sys.stdout.write('Error: Ambiguous command: {}'.format(comm))
print 'Error: Ambiguous command: {}'.format(comm)
else:
print 'Error: Unrecognized command {}'.format(comm)
print 'Error: Unrecognized command: {}'.format(comm)
# We are overriding do_help to avoid printing info about