From 28de7872706bf5e0f66f7f4dce54ca684978fab3 Mon Sep 17 00:00:00 2001 From: ExE Boss Date: Sun, 20 Aug 2017 18:02:08 +0200 Subject: [PATCH] =?UTF-8?q?Only=20enable=20=E2=80=9CSave=20Page=20As?= =?UTF-8?q?=E2=80=A6=E2=80=9D=20if=20we=20can=20load=20the=20content=20scr?= =?UTF-8?q?ipt.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This avoids the issue with `about:`, `chrome://` and `resource://` URLs not being downloadable. --- src/background.js | 1 - src/content/content.js | 3 ++- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/background.js b/src/background.js index dd3be2b..11934dc 100644 --- a/src/background.js +++ b/src/background.js @@ -116,7 +116,6 @@ async function handlePopupMessage(message) { ], enable: [ "new*", - "saveAs", "emailLink", "devGetTools", "openAddons", diff --git a/src/content/content.js b/src/content/content.js index df568aa..8a50f78 100644 --- a/src/content/content.js +++ b/src/content/content.js @@ -27,7 +27,8 @@ if (!amLoaded) { let result = { disable: [], enable: [ - "print" + "print", + "saveAs" ] } if (document.documentElement.requestFullScreen || document.documentElement.mozRequestFullScreen) {