diff --git a/browser/components/customizableui/src/CustomizableUI.jsm b/browser/components/customizableui/src/CustomizableUI.jsm index 50f94ed8b955..4deaa6607791 100644 --- a/browser/components/customizableui/src/CustomizableUI.jsm +++ b/browser/components/customizableui/src/CustomizableUI.jsm @@ -1275,7 +1275,6 @@ let CustomizableUIInternal = { shortcut = ShortcutUtils.findShortcut(document.getElementById(commandId)); } if (!shortcut) { - ERROR("Could not find a keyboard shortcut for '" + aShortcutNode.outerHTML + "'."); return; } diff --git a/browser/components/customizableui/src/CustomizableWidgets.jsm b/browser/components/customizableui/src/CustomizableWidgets.jsm index 593cfb1803d9..13606b1b0bd4 100644 --- a/browser/components/customizableui/src/CustomizableWidgets.jsm +++ b/browser/components/customizableui/src/CustomizableWidgets.jsm @@ -52,7 +52,7 @@ function setAttributes(aNode, aAttrs) { let additionalArgs = []; if (aAttrs.shortcutId) { let shortcut = doc.getElementById(aAttrs.shortcutId); - if (doc) { + if (shortcut) { additionalArgs.push(ShortcutUtils.prettifyShortcut(shortcut)); } }