Fix chart saving on Linux/Mac (#148)

* Fix chart saving on Linux/Mac

* No need for back slashes actually!!
This commit is contained in:
swordcube
2023-06-16 00:37:56 +02:00
committed by GitHub
parent ef000bb0f5
commit d9de98fd5c
+5 -5
View File
@@ -176,11 +176,11 @@ class Chart {
var meta = filteredChart.meta;
#if sys
if (!FileSystem.exists('${songFolderPath}\\charts\\'))
FileSystem.createDirectory('${songFolderPath}\\charts\\');
if (!FileSystem.exists('${songFolderPath}/charts/'))
FileSystem.createDirectory('${songFolderPath}/charts/');
var chartPath = '${songFolderPath}\\charts\\${difficulty.trim()}.json';
var metaPath = '${songFolderPath}\\meta.json';
var chartPath = '${songFolderPath}/charts/${difficulty.trim()}.json';
var metaPath = '${songFolderPath}/meta.json';
File.saveContent(chartPath, Json.stringify(filteredChart, null, saveSettings.prettyPrint == true ? "\t" : null));
@@ -216,4 +216,4 @@ typedef ChartSaveSettings = {
var ?overrideExistingMeta:Bool;
var ?saveMetaInChart:Bool;
var ?prettyPrint:Bool;
}
}