Skip to content

Commit 66b3822

Browse files
committed
Use Background Thread For Async Saving
1 parent 17e128b commit 66b3822

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

src/main/java/the/bytecode/club/bytecodeviewer/SettingsSerializer.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,7 @@ public class SettingsSerializer
4343

4444
public static void saveSettingsAsync()
4545
{
46-
Thread saveThread = new Thread(SettingsSerializer::saveSettings, "Save Settings");
47-
saveThread.start();
46+
BytecodeViewer.getTaskManager().doOnce(task -> saveSettings());
4847
}
4948

5049
public static synchronized void saveSettings()

0 commit comments

Comments
 (0)