From ce04ba71b880aeb97b7d47d404ba4ea430891618 Mon Sep 17 00:00:00 2001 From: Ju1-js <40339350+Ju1-js@users.noreply.github.com> Date: Thu, 8 Dec 2022 22:47:45 -0800 Subject: [PATCH] Make # settings changed message grammatically correct Make the ": " in the settings changed message not show if 0 settings were changed. "0 settings changed: ." -> "0 settings changed." --- modules/ui.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/ui.py b/modules/ui.py index b2b8de90..79bb3d1f 100644 --- a/modules/ui.py +++ b/modules/ui.py @@ -1450,7 +1450,7 @@ def create_ui(): opts.save(shared.config_filename) except RuntimeError: return opts.dumpjson(), f'{len(changed)} settings changed without save: {", ".join(changed)}.' - return opts.dumpjson(), f'{len(changed)} settings changed: {", ".join(changed)}.' + return opts.dumpjson(), f'{len(changed)} settings changed{": " if len(changed) > 0 else ""}{", ".join(changed)}.' def run_settings_single(value, key): if not opts.same_type(value, opts.data_labels[key].default):