mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-04-12 03:57:27 +00:00
fix PresetsList saving to file
This commit is contained in:
parent
cc159e306e
commit
ae03b8cd7e
1 changed files with 2 additions and 3 deletions
|
|
@ -266,14 +266,13 @@ namespace PepperDash.Essentials.Core.Presets
|
|||
try
|
||||
{
|
||||
_fileOps.Enter();
|
||||
var json = JsonConvert.SerializeObject(PresetsList);
|
||||
var pl = new PresetsList {Channels = PresetsList, Name = Name};
|
||||
var json = JsonConvert.SerializeObject(pl, Formatting.Indented);
|
||||
|
||||
using (var file = File.Open(_filePath, FileMode.Truncate))
|
||||
{
|
||||
file.Write(json, Encoding.UTF8);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue