summaryrefslogtreecommitdiff
path: root/django
diff options
context:
space:
mode:
authorMariusz Felisiak <felisiak.mariusz@gmail.com>2022-07-31 07:48:52 +0200
committerMariusz Felisiak <felisiak.mariusz@gmail.com>2022-08-03 08:09:59 +0200
commit080359c4c5242ef69ac8c58c92f240e71121ffd7 (patch)
tree0ea5b4b419294a5c74b62db00c2c54c456b435cd /django
parent1a9f079b7e43c0045f380729ba5fd7cfaa137bd5 (diff)
[4.0.x] Fixed warnings per flake8 5.0.0.
Backport of c18861804feb6a97afbeabb51be748dd60a04458 from main.
Diffstat (limited to 'django')
-rw-r--r--django/contrib/contenttypes/management/commands/remove_stale_contenttypes.py24
1 files changed, 12 insertions, 12 deletions
diff --git a/django/contrib/contenttypes/management/commands/remove_stale_contenttypes.py b/django/contrib/contenttypes/management/commands/remove_stale_contenttypes.py
index aa42d0192f..edddaa29a4 100644
--- a/django/contrib/contenttypes/management/commands/remove_stale_contenttypes.py
+++ b/django/contrib/contenttypes/management/commands/remove_stale_contenttypes.py
@@ -72,18 +72,18 @@ class Command(BaseCommand):
)
content_type_display = "\n".join(ct_info)
self.stdout.write(
- """Some content types in your database are stale and can be deleted.
-Any objects that depend on these content types will also be deleted.
-The content types and dependent objects that would be deleted are:
-
-%s
-
-This list doesn't include any cascade deletions to data outside of Django's
-models (uncommon).
-
-Are you sure you want to delete these content types?
-If you're unsure, answer 'no'."""
- % content_type_display
+ "Some content types in your database are stale and can be "
+ "deleted.\n"
+ "Any objects that depend on these content types will also be "
+ "deleted.\n"
+ "The content types and dependent objects that would be deleted "
+ "are:\n\n"
+ f"{content_type_display}\n\n"
+ "This list doesn't include any cascade deletions to data "
+ "outside of Django's\n"
+ "models (uncommon).\n\n"
+ "Are you sure you want to delete these content types?\n"
+ "If you're unsure, answer 'no'."
)
ok_to_delete = input("Type 'yes' to continue, or 'no' to cancel: ")
else: