From d588283fb2e0a8cafef5b19b0a859d9bc02aee54 Mon Sep 17 00:00:00 2001 From: Omar Rizwan Date: Thu, 31 Dec 2020 18:00:25 -0800 Subject: Firefox fixes, md update --- extension/background.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'extension') diff --git a/extension/background.js b/extension/background.js index a78a7fd..1b1cad0 100644 --- a/extension/background.js +++ b/extension/background.js @@ -54,7 +54,7 @@ async function detachDebugger(tabId) { } const TabManager = (function() { if (TESTING) return; - chrome.debugger.onEvent.addListener((source, method, params) => { + if (chrome.debugger) chrome.debugger.onEvent.addListener((source, method, params) => { console.log(source, method, params); if (method === "Page.frameStartedLoading") { // we're gonna assume we're always plugged into both Page and Debugger. @@ -347,6 +347,7 @@ router["/tabs/by-id/*/control"] = { // debugger/ : debugger-API-dependent (Chrome-only) (function() { + if (!chrome.debugger) return; // possible idea: console (using Log API instead of monkey-patching) // resources/ // TODO: scripts/ TODO: allow creation, eval immediately -- cgit v1.2.3