Update applyPatches.ts

This commit is contained in:
TrèsAbhi authored and GitHub committed 2025-01-18 11:41:45 -06:00
1 parent cc4569966e
commit e482fd40c1
1 file changed
+8 -1
+8 -1
View File
@@ -47,9 +47,16 @@ while (true) {
);
for (const { path, data } of files) {
console.log(`Patching "${path}"...`);
const { dir } = parsePath(path);
await mkdir(`${DATA}/${dir}`, { recursive: true });
try {
await mkdir(`${DATA}/${dir}`, { recursive: true });
} catch (error) {
console.warn(`Failed to make directory "${dir}"`);
}
await writeFile(
`${DATA}/${path}`,
new Uint8Array(writeDVPL(Buffer.from(data))),