Merge pull request #274 from waldbrand/improve-theme-file-filtering

When filtering theme files, be a bit more strict
This commit is contained in:
Pieter Vander Vennet 2021-05-13 12:24:37 +02:00 committed by GitHub
commit 8d32da82bb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -29,7 +29,7 @@ const layerFiles = ScriptUtils.readDirRecSync("./assets/layers")
}
})
const themeFiles: any[] = ScriptUtils.readDirRecSync("./assets/themes")
.filter(path => path.indexOf(".json") > 0)
.filter(path => path.endsWith(".json"))
.filter(path => path.indexOf("license_info.json") < 0)
.map(path => {
return JSON.parse(readFileSync(path, "UTF8"));