From 400beacb7072fdc529b4405235d877bfcca8283d Mon Sep 17 00:00:00 2001 From: TRIGUBF Date: Wed, 23 Aug 2023 16:50:35 +0200 Subject: [PATCH] revoke url, remove anchor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Fredrik Adelöw --- .../src/components/TemplateEditorPage/DryRunContext.tsx | 2 ++ yarn.lock | 6 +++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/plugins/scaffolder/src/components/TemplateEditorPage/DryRunContext.tsx b/plugins/scaffolder/src/components/TemplateEditorPage/DryRunContext.tsx index 47d121b616..530b9f5be1 100644 --- a/plugins/scaffolder/src/components/TemplateEditorPage/DryRunContext.tsx +++ b/plugins/scaffolder/src/components/TemplateEditorPage/DryRunContext.tsx @@ -227,5 +227,7 @@ async function createZipDownload(directoryContents: { path: string; base64Conten a.href = URL.createObjectURL(zipFileBlob); a.download = `dry-run-${name}.zip`; a.click(); + URL.revokeObjectURL(a.href); + a.remove(); } diff --git a/yarn.lock b/yarn.lock index 00e3730ac1..f7e0fb0f75 100644 --- a/yarn.lock +++ b/yarn.lock @@ -19348,9 +19348,9 @@ __metadata: linkType: hard "@zip.js/zip.js@npm:^2.7.24": - version: 2.7.28 - resolution: "@zip.js/zip.js@npm:2.7.28" - checksum: 2447e7250daeb0a518c68347034075ad244e8e53e3ee83a2e3e078f919328edcc24a6c68f1814d42e231526230360164cce79d70f14cb9a16a07e91ae1e25257 + version: 2.7.24 + resolution: "@zip.js/zip.js@npm:2.7.24" + checksum: f56f973748d063158cbb6f07ccf4d4c64d35952bb2ecf3d9922db935b17f4e689b6d8568041083195ff4679a0d1a9378fa78adca7428819239d4a3fb4a1dd2d2 languageName: node linkType: hard