diff --git a/src/plugins/webContextMenus.web.ts b/src/plugins/webContextMenus.web.ts index e1c9725d..6b193e59 100644 --- a/src/plugins/webContextMenus.web.ts +++ b/src/plugins/webContextMenus.web.ts @@ -193,7 +193,7 @@ export default definePlugin({ const data = await fetchImage(url); if (!data) return; - const name = url.split("/").pop()!; + const name = new URL(url).pathname.split("/").pop()!; const file = new File([data], name, { type: data.type }); saveFile(file);