fixed a bug in cmds module