fixed import error on edges
This commit is contained in:
parent
712dcf3535
commit
43ef297263
1 changed files with 3 additions and 3 deletions
|
|
@ -335,7 +335,7 @@ export function scapedJSONStringfy(json: object): string {
|
||||||
return customStringify(json).replace(/"/g, '\\"');
|
return customStringify(json).replace(/"/g, '\\"');
|
||||||
}
|
}
|
||||||
export function scapeJSONParse(json: string): any {
|
export function scapeJSONParse(json: string): any {
|
||||||
console.log(json);
|
console.log(json, json.replace(/\\"/g, '"'));
|
||||||
return JSON.parse(json.replace(/\\"/g, '"'));
|
return JSON.parse(json.replace(/\\"/g, '"'));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -350,10 +350,10 @@ export function checkOldEdgesHandles(edges: Edge[]): boolean {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
function customStringify(obj: any) {
|
function customStringify(obj: any): string {
|
||||||
console.log(obj);
|
console.log(obj);
|
||||||
if (typeof obj === "undefined") {
|
if (typeof obj === "undefined") {
|
||||||
return "undefined";
|
return '"undefined"';
|
||||||
}
|
}
|
||||||
|
|
||||||
if (obj === null || typeof obj !== "object") {
|
if (obj === null || typeof obj !== "object") {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue