Skip to content

Commit c2f8480

Browse files
committed
Revert "Test save error"
This reverts commit 2d6667b.
1 parent 2d6667b commit c2f8480

File tree

1 file changed

+4
-8
lines changed

1 file changed

+4
-8
lines changed

Flow.Launcher.Infrastructure/Storage/JsonStorage.cs

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -180,24 +180,20 @@ private void BackupOriginFile()
180180

181181
public void Save()
182182
{
183-
throw new NotImplementedException("Save error");
184-
185-
/*string serialized = JsonSerializer.Serialize(Data,
183+
string serialized = JsonSerializer.Serialize(Data,
186184
new JsonSerializerOptions { WriteIndented = true });
187185

188186
File.WriteAllText(TempFilePath, serialized);
189187

190-
AtomicWriteSetting();*/
188+
AtomicWriteSetting();
191189
}
192190

193191
public async Task SaveAsync()
194192
{
195-
throw new NotImplementedException("SaveAsync error");
196-
197-
/*await using var tempOutput = File.OpenWrite(TempFilePath);
193+
await using var tempOutput = File.OpenWrite(TempFilePath);
198194
await JsonSerializer.SerializeAsync(tempOutput, Data,
199195
new JsonSerializerOptions { WriteIndented = true });
200-
AtomicWriteSetting();*/
196+
AtomicWriteSetting();
201197
}
202198

203199
private void AtomicWriteSetting()

0 commit comments

Comments
 (0)