From 907507ca8a9423d05b8f86d107c4158ceae053ea Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Thu, 23 Aug 2012 18:22:54 +0200 Subject: some work on configurations --- ponysay | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'ponysay') diff --git a/ponysay b/ponysay index f70cb2d..4f3f19f 100755 --- a/ponysay +++ b/ponysay @@ -864,8 +864,8 @@ class ArgParser(): elif dashed: self.files.append(arg) elif arg == '++': tmpdashed = True elif arg == '--': dashed = True - elif (len(arg) > 1) and ((arg[0] == '-') or (arg[0] == '+')): - if (len(arg) > 2) and ((arg[:2] == '--') or (arg[:2] == '++')): + elif (len(arg) > 1) and (arg[0] in ('-', '+')): + if (len(arg) > 2) and (arg[:2] in ('--', '++')): if dontget > 0: dontget -= 1 elif (arg in self.optmap) and (self.optmap[arg][1] == ARGUMENTLESS): -- cgit