From 65ebdad2a336361e82feaab19e6b0be707886d25 Mon Sep 17 00:00:00 2001 From: Dimitris Zlatanidis Date: Fri, 17 Mar 2023 21:55:04 +0200 Subject: [PATCH] Fixed for recurring options --- slpkg/main.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/slpkg/main.py b/slpkg/main.py index fdc4cc78..05c1c525 100644 --- a/slpkg/main.py +++ b/slpkg/main.py @@ -283,9 +283,9 @@ class Argparse(Configs): if opt[0] == '-' and opt in self.options: if self.flags.count(opt) > 1: repeat.append(opt) - if len(opt) > 2: - if opt == self.options[self.options.index(opt)]: - repeat.append(opt) + if opt[:2] == '--': + if opt == self.options[self.options.index(opt)]: + repeat.append(opt) # Fixed for recurring options. if repeat: