diff --git a/keyserver/src/utils/import-json.js b/keyserver/src/utils/import-json.js --- a/keyserver/src/utils/import-json.js +++ b/keyserver/src/utils/import-json.js @@ -1,5 +1,7 @@ // @flow +import fs from 'fs'; + type ConfigName = { +folder: 'secrets' | 'facts', +name: string, @@ -42,9 +44,7 @@ } const path = getPathForConfigName(configName); try { - // $FlowFixMe - const importedJSON = await import(`../../${path}`); - return importedJSON.default; + return JSON.parse(fs.readFileSync(path, 'utf8')); } catch { return null; }