loadFromFs: clean up

This commit is contained in:
wukko
2024-05-15 22:28:31 +06:00
parent 98e05368ed
commit c2678888be

View File

@ -3,14 +3,14 @@ import * as fs from "fs";
export function loadJSON(path) {
try {
return JSON.parse(fs.readFileSync(path, 'utf-8'))
} catch(e) {
} catch {
return false
}
}
export function loadFile(path) {
try {
return fs.readFileSync(path, 'utf-8')
} catch(e) {
} catch {
return false
}
}