From b70d022b34f496b5ff05b9836cdb044f12e02c0e Mon Sep 17 00:00:00 2001 From: Santo Cariotti Date: Thu, 20 Jul 2017 18:30:08 +0200 Subject: fixed errors --- lib/commands.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/commands.py b/lib/commands.py index a3d439a..95f3563 100644 --- a/lib/commands.py +++ b/lib/commands.py @@ -27,9 +27,11 @@ class Commands(object): print('Ok') elif cmd[1] is not ListCommands.commands['set']: - raise IndexError + raise KeyError except IndexError: ListCommands.err('wrong') + except KeyError: + ListCommands.err('keyword') except PersonalError as e: ListCommands.err('personal', e.value) elif what == 'get': -- cgit v1.2.3-18-g5258