not failing on invalid p2p files

This commit is contained in:
mrfry 2023-04-08 18:19:12 +02:00
parent e46fed69c3
commit dbe6272240
4 changed files with 20 additions and 5 deletions

View file

@ -24,6 +24,7 @@ export const validateFiles = (): boolean => {
Object.entries(files).forEach(([key, file]: [string, FileDescriptor]) => {
let fileExists = utils.FileExists(file.path)
if (file.defaultValue != null && !fileExists) {
// FIXME: create path too
utils.WriteFile(file.defaultValue, file.path)
fileExists = true
}