mirror of
https://github.com/Nezumi-2711/next-gdrive-index.git
synced 2026-09-22 13:38:38 +00:00
fix: Load v2.0.4 config failed because of triple double quotes
This commit is contained in:
@@ -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;
|
||||
|
||||
Reference in New Issue
Block a user