From faa564677628f94deea6a3e2b1898907d15f2ad7 Mon Sep 17 00:00:00 2001 From: Paul Hebble Date: Thu, 15 Feb 2024 11:44:24 -0600 Subject: [PATCH] Set default command lines if empty on config load --- GUI/Model/GUIConfiguration.cs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/GUI/Model/GUIConfiguration.cs b/GUI/Model/GUIConfiguration.cs index e57a86645..d8ad9cd3f 100644 --- a/GUI/Model/GUIConfiguration.cs +++ b/GUI/Model/GUIConfiguration.cs @@ -204,6 +204,12 @@ private static bool DeserializationFixes(GUIConfiguration configuration, configuration.CommandLineArguments = null; needsSave = true; } + else if (configuration.CommandLines.Count < 1) + { + // Don't leave the list empty if user switches CKAN versions + configuration.CommandLines.AddRange(defaultCommandLines); + needsSave = true; + } return needsSave; }