fix: clear file store when navigating between tools

Changed undoProcessing() to reset() on toolId change so files don't
persist when navigating from one tool to another. Previously a video
file from a video tool would carry over to an image tool.
This commit is contained in:
SnapOtter
2026-06-14 21:32:27 +08:00
parent 90acd5bcd9
commit f32b3bd51f
+1 -1
View File
@@ -333,7 +333,7 @@ export function ToolPage() {
// biome-ignore lint/correctness/useExhaustiveDependencies: toolId triggers intentional reset on tool navigation
useEffect(() => {
useFileStore.getState().undoProcessing();
useFileStore.getState().reset();
useBase64Store.getState().reset();
useCollageStore.getState().reset();