Skip to content

Commit

Permalink
Remove older matches files removal, because it causes exceptions some…
Browse files Browse the repository at this point in the history
…times
  • Loading branch information
savannstm committed Aug 31, 2024
1 parent ce75e10 commit 5c3a489
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 10 deletions.
2 changes: 1 addition & 1 deletion src-tauri/tauri.conf.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"readDir": true,
"readFile": true,
"removeDir": true,
"removeFile": true,
"removeFile": false,
"renameFile": false,
"scope": ["**"],
"writeFile": true
Expand Down
9 changes: 0 additions & 9 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ import {
readBinaryFile,
readDir,
readTextFile,
removeFile,
writeBinaryFile,
writeTextFile,
} from "@tauri-apps/api/fs";
Expand Down Expand Up @@ -611,14 +610,6 @@ document.addEventListener("DOMContentLoaded", async () => {
return;
}

const programDataFiles = await readDir(await join(settings.projectPath, programDataDir));

for (const file of programDataFiles) {
if (file.name?.startsWith("matches")) {
await removeFile(file.path);
}
}

const results = replace ? new Map<HTMLTextAreaElement, string>() : null;
const objectToWrite = new Map<string, string>();
let file = 0;
Expand Down

0 comments on commit 5c3a489

Please sign in to comment.