From 810cd400166c0d8d28c3a2178e8c3d42dd7b7107 Mon Sep 17 00:00:00 2001 From: kingbri Date: Sun, 8 Sep 2024 21:31:18 -0400 Subject: [PATCH] Start: Broadcast start_options only on first-time run Prevents the save from occurring multiple times for no reason. Signed-off-by: kingbri --- start.py | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/start.py b/start.py index 490570e..844976f 100644 --- a/start.py +++ b/start.py @@ -234,15 +234,15 @@ if __name__ == "__main__": if first_run: start_options["first_run_done"] = True - # Save start options - with open("start_options.json", "w") as start_file: - start_file.write(json.dumps(start_options)) + # Save start options + with open("start_options.json", "w") as start_file: + start_file.write(json.dumps(start_options)) - print( - "Successfully wrote your start script options to `start_options.json`. \n" - "If something goes wrong, editing or deleting the file " - "will reinstall TabbyAPI as a first-time user." - ) + print( + "Successfully wrote your start script options to `start_options.json`. \n" + "If something goes wrong, editing or deleting the file " + "will reinstall TabbyAPI as a first-time user." + ) # Import entrypoint after installing all requirements try: