From 865e0e588680ca43f885020b82053cea541fc2b1 Mon Sep 17 00:00:00 2001 From: Hugo Locurcio Date: Sat, 22 Jan 2022 16:44:52 +0100 Subject: [PATCH] Fix missing space before "and" in package list Example message which I recently received: > The following packages may be outdated: Gaugesand More Ores This should now be: > The following packages may be outdated: Gauges and More Ores --- app/blueprints/admin/actions.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/blueprints/admin/actions.py b/app/blueprints/admin/actions.py index b6a88ef..fdf993b 100644 --- a/app/blueprints/admin/actions.py +++ b/app/blueprints/admin/actions.py @@ -187,10 +187,10 @@ def run_update_config(): def _package_list(packages: List[str]): # Who needs translations? if len(packages) >= 3: - packages[len(packages) - 1] = "and " + packages[len(packages) - 1] + packages[len(packages) - 1] = " and " + packages[len(packages) - 1] packages_list = ", ".join(packages) else: - packages_list = "and ".join(packages) + packages_list = " and ".join(packages) return packages_list @action("Send WIP package notification") @@ -287,4 +287,4 @@ def delete_inactive_users(): users = User.query.filter(User.is_active==False, User.packages==None, User.forum_topics==None, User.rank==UserRank.NOT_JOINED).all() for user in users: db.session.delete(user) - db.session.commit() \ No newline at end of file + db.session.commit()