Even better validation

This commit is contained in:
Ludovic Stephan 2020-11-21 19:21:43 +01:00
parent 583586c01a
commit 6b94a0a95e

View file

@ -36,7 +36,7 @@ class Command(BaseCommand):
else: else:
promo = self.get_current_promo() promo = self.get_current_promo()
if promo < 2000: if promo < 2000 or promo > 2100:
raise CommandError("Promotion invalide : {}".format(promo)) raise CommandError("Promotion invalide : {}".format(promo))
verbosity = options["verbosity"] verbosity = options["verbosity"]