fix: Load v2.0.4 config failed because of triple double quotes

This commit is contained in:
mbaharip
2025-01-28 07:34:35 +07:00
parent 5cba2f7452
commit b8b1d34557
+1
View File
@@ -621,6 +621,7 @@ export function parseVersion2Config(configuration: string) {
.replace(/,(?=[^,]*$)/, "") // Remove trailing comma
.replace(/(,\])/g, "]") // Remove trailing comma before closing bracket
.replace(/(,\})/g, "}") // Remove trailing comma before closing brace
.replace(/\"{3,}/g, '"') // Remove multiple double quotes
.slice(0, -1);
const json = JSON.parse(config) as object;