1
0
mirror of https://github.com/mail-in-a-box/mailinabox.git synced 2026-03-08 16:27:24 +01:00

Fixed UP031 (printf-string-formatting): Use format specifiers instead of percent format

This commit is contained in:
Teal Dulcet
2025-01-12 06:36:07 -08:00
parent 1782b69405
commit 1d1a1a09c4
8 changed files with 29 additions and 29 deletions

View File

@@ -196,7 +196,7 @@ def get_current_migration():
ver = 0
while True:
next_ver = (ver + 1)
migration_func = globals().get("migration_%d" % next_ver)
migration_func = globals().get("migration_{:d}".format(next_ver))
if not migration_func:
return ver
ver = next_ver
@@ -228,14 +228,14 @@ def run_migrations():
while True:
next_ver = (ourver + 1)
migration_func = globals().get("migration_%d" % next_ver)
migration_func = globals().get("migration_{:d}".format(next_ver))
if not migration_func:
# No more migrations to run.
break
print()
print("Running migration to Mail-in-a-Box #%d..." % next_ver)
print("Running migration to Mail-in-a-Box #{:d}...".format(next_ver))
try:
migration_func(env)