diff --git a/apps/yaak-client/hooks/useSaveResponse.tsx b/apps/yaak-client/hooks/useSaveResponse.tsx index 31bb2575..eda2c9b6 100644 --- a/apps/yaak-client/hooks/useSaveResponse.tsx +++ b/apps/yaak-client/hooks/useSaveResponse.tsx @@ -25,6 +25,10 @@ export function useSaveResponse(response: HttpResponse | null) { defaultPath: ext ? `${slug}.${ext}` : slug, title: "Save Response", }); + if (filepath == null) { + return; // Cancelled + } + await rpc("cmd_save_response", { responseId: response.id, filepath }); showToast({ message: (