Skip to content

armgit / Cap

Public Imported from GitHub
0

Open source Loom alternative. Beautiful, shareable screen recordings.

Throw SilentError on export cancellation

Richie McIlroycdc91c015975
diff --git a/apps/desktop/src/routes/editor/ExportDialog.tsx b/apps/desktop/src/routes/editor/ExportDialog.tsx
index fc8c23b41..354b5aefa 100644
--- a/apps/desktop/src/routes/editor/ExportDialog.tsx
+++ b/apps/desktop/src/routes/editor/ExportDialog.tsx
@@ -249,7 +249,7 @@ export function ExportDialog() {
setExportState(reconcile({ action: "copy", type: "starting" }));
const outputPath = await exportWithSettings((progress) => {
- if (isCancelled()) return;
+ if (isCancelled()) throw new SilentError("Cancelled");
setExportState({ type: "rendering", progress });
});
@@ -320,7 +320,7 @@ export function ExportDialog() {
});
const videoPath = await exportWithSettings((progress) => {
- if (isCancelled()) return;
+ if (isCancelled()) throw new SilentError("Cancelled");
setExportState({ type: "rendering", progress });
});
@@ -403,7 +403,7 @@ export function ExportDialog() {
});
await exportWithSettings((progress) => {
- if (isCancelled()) return;
+ if (isCancelled()) throw new SilentError("Cancelled");
setExportState({ type: "rendering", progress });
});