mirror of
https://github.com/SabreTools/MPF.git
synced 2026-07-02 17:24:48 +00:00
Fix minor issues with options loading
This commit is contained in:
@@ -23,6 +23,7 @@
|
||||
- More consistency in commandline programs
|
||||
- Use GC.SharpCompress as archive handling library
|
||||
- Start wiring through log compression changes
|
||||
- Fix minor issues with options loading
|
||||
|
||||
### 3.4.2 (2025-09-30)
|
||||
|
||||
|
||||
@@ -570,7 +570,7 @@ namespace MPF.Frontend
|
||||
}
|
||||
set
|
||||
{
|
||||
Settings["InternalProgram"] = value.ToString();
|
||||
Settings["LogCompression"] = value.ToString();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -188,12 +188,9 @@ namespace MPF.Frontend.Tools
|
||||
if (string.IsNullOrEmpty(ConfigurationPath))
|
||||
return new Options();
|
||||
|
||||
// Ensure the file exists
|
||||
// If the file does not exist
|
||||
if (!File.Exists(ConfigurationPath) || new FileInfo(ConfigurationPath).Length == 0)
|
||||
{
|
||||
File.Create(ConfigurationPath).Dispose();
|
||||
return new Options();
|
||||
}
|
||||
|
||||
var serializer = JsonSerializer.Create();
|
||||
var stream = File.Open(ConfigurationPath, FileMode.Open, FileAccess.Read, FileShare.ReadWrite);
|
||||
|
||||
Reference in New Issue
Block a user