Updated for flags error

This commit is contained in:
Dimitris Zlatanidis 2023-01-09 22:38:30 +02:00
parent 8f2bdb5ea8
commit 1af73e6656

View file

@ -152,8 +152,11 @@ class Argparse:
self.usage.help(1)
def update(self):
if [f for f in self.flags if f not in [self.flag_yes]]:
self.usage.help(1)
command = Argparse.upgrade.__name__
update_flags = [self.flag_yes]
if [f for f in self.flags if f not in update_flags]:
self.usage.error_for_options(command, update_flags)
if len(self.args) == 1:
update = UpdateRepository(self.flags)