diff --git a/Source/AppScaffolding/LibationScaffolding.cs b/Source/AppScaffolding/LibationScaffolding.cs index 5a86d7b3..917ac9d7 100644 --- a/Source/AppScaffolding/LibationScaffolding.cs +++ b/Source/AppScaffolding/LibationScaffolding.cs @@ -7,6 +7,7 @@ using Newtonsoft.Json; using Newtonsoft.Json.Linq; using Serilog; using System; +using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Linq; @@ -406,6 +407,12 @@ namespace AppScaffolding } } + class FilterState_6_6_9 + { + public bool UseDefault { get; set; } + public List Filters { get; set; } = new(); + } + public static void migrate_to_v11_5_0(Configuration config) { // Read file, but convert old format to new (with Name field) as necessary. @@ -431,8 +438,8 @@ namespace AppScaffolding try { - if (JsonConvert.DeserializeObject(File.ReadAllText(QuickFilters.JsonFile)) - is QuickFilters.OldFilterState inMemState) + if (JsonConvert.DeserializeObject(File.ReadAllText(QuickFilters.JsonFile)) + is FilterState_6_6_9 inMemState) { // Copy old structure to new. QuickFilters.InMemoryState = new(); diff --git a/Source/LibationFileManager/QuickFilters.cs b/Source/LibationFileManager/QuickFilters.cs index 97500c25..82a5c1ae 100644 --- a/Source/LibationFileManager/QuickFilters.cs +++ b/Source/LibationFileManager/QuickFilters.cs @@ -14,12 +14,6 @@ namespace LibationFileManager public static event EventHandler? UseDefaultChanged; - public class OldFilterState - { - public bool UseDefault { get; set; } - public List Filters { get; set; } = new(); - } - public class FilterState { public bool UseDefault { get; set; }