From 1cc3a3736eefaa263f632537ae684dd14eba44da Mon Sep 17 00:00:00 2001 From: Myned Date: Tue, 17 Oct 2017 18:04:43 -0400 Subject: [PATCH] Should fix wrong error catching --- src/main/utils/utils.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main/utils/utils.py b/src/main/utils/utils.py index 3cd27e2..914c8d9 100644 --- a/src/main/utils/utils.py +++ b/src/main/utils/utils.py @@ -124,7 +124,7 @@ def get_args(ctx, args, *, rem=False, rm=False, lim=False): try: remaining.remove('-d') - except KeyError: + except ValueError: remaining.remove('-dm') if rm: @@ -134,10 +134,10 @@ def get_args(ctx, args, *, rem=False, rm=False, lim=False): try: remaining.remove('-r') - except KeyError: + except ValueError: try: remaining.remove('-rm') - except KeyError: + except ValueError: remaining.remove('-remove') if lim: