(path: string)
| 5 | * Loads CJSON from given path. |
| 6 | */ |
| 7 | export function loadCJSON(path: string): any { |
| 8 | try { |
| 9 | return cjson.load(path); |
| 10 | } catch (e: any) { |
| 11 | if (e.code === "ENOENT") { |
| 12 | throw new FirebaseError(`File ${path} does not exist`); |
| 13 | } |
| 14 | throw new FirebaseError(`Parse Error in ${path}:\n\n${e.message}`); |
| 15 | } |
| 16 | } |
no test coverage detected
searching dependent graphs…