Update common.ts

This commit is contained in:
Freddie Wang 2020-12-22 17:34:25 +08:00 committed by GitHub
parent 0312d7dcf2
commit 7a97396340
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -20,7 +20,7 @@ export const forte_permitted_list = {
}
async function ReadData(filename: string) {
if (!IO.Exists(`data/${filename}.xml`)) {
if (!IO.Exists(`data/${filename}.json.b64`)) {
const xml = await IO.ReadFile(`data/${filename}.xml`, 'utf-8');
const json = U.parseXML(xml, false)
// await IO.WriteFile(`data/${filename}.json.b64`, Buffer.from(JSON.stringify(json)).toString('base64'));