Format demo purge for Jenkins lint

This commit is contained in:
2026-04-06 02:42:58 +02:00
parent 5f0c7bd9b9
commit 4003f698d2

View File

@@ -76,11 +76,7 @@ class Command(BaseCommand):
"template", "template",
] ]
qs = ( qs = Page.objects.exclude(depth=1).exclude(slug__in=["home"]).specific()
Page.objects.exclude(depth=1)
.exclude(slug__in=["home"])
.specific()
)
candidates = [] candidates = []
for page in qs: for page in qs:
@@ -142,7 +138,9 @@ class Command(BaseCommand):
try: try:
for product in iterable: for product in iterable:
removed += 1 removed += 1
self.stdout.write(f"PRODUCT delete id={product.id} title={product.title}") self.stdout.write(
f"PRODUCT delete id={product.id} title={product.title}"
)
product.delete() product.delete()
finally: finally:
register_signal_handlers() register_signal_handlers()