Bug 1288558 - Enable eslint no-undef for shipping pwmgr code. r=me

MozReview-Commit-ID: 5rbPmxODejr

--HG--
extra : rebase_source : e4313608623e22d8bf15a7bd605a96be9a437d49
This commit is contained in:
Matthew Noorenberghe 2016-09-07 18:44:17 -07:00
parent b933ef7e2a
commit 7b4ec0f6cf
5 changed files with 8 additions and 4 deletions

View File

@ -10,6 +10,9 @@
// Commas at the end of the line not the start
"comma-style": 2,
// No using undeclared variables
"no-undef": 2,
// Don't allow unused local variables unless they match the pattern
"no-unused-vars": [2, {"args": "none", "vars": "local", "varsIgnorePattern": "^(ids|ignored|unused)$"}],
}

View File

@ -484,9 +484,9 @@ function HandleSignonKeyPress(e) {
if (signonsTree.getAttribute("editing")) {
return;
}
if (e.keyCode == KeyEvent.DOM_VK_DELETE ||
if (e.keyCode == KeyboardEvent.DOM_VK_DELETE ||
(AppConstants.platform == "macosx" &&
e.keyCode == KeyEvent.DOM_VK_BACK_SPACE))
e.keyCode == KeyboardEvent.DOM_VK_BACK_SPACE))
{
DeleteSignon();
}

View File

@ -12,7 +12,7 @@ Cu.import("resource://gre/modules/AppConstants.jsm");
Cu.import("resource://gre/modules/XPCOMUtils.jsm");
Cu.import("resource://gre/modules/Services.jsm");
Cu.import("resource://gre/modules/Timer.jsm");
Cu.import("resource://gre/modules/LoginManagerContent.jsm");
Cu.import("resource://gre/modules/LoginManagerContent.jsm"); /*global UserAutoCompleteResult */
XPCOMUtils.defineLazyModuleGetter(this, "Promise",
"resource://gre/modules/Promise.jsm");

View File

@ -7,7 +7,7 @@ const { classes: Cc, interfaces: Ci, results: Cr, utils: Cu } = Components;
Cu.import("resource://gre/modules/XPCOMUtils.jsm");
Cu.import("resource://gre/modules/Services.jsm");
Cu.import("resource://gre/modules/PrivateBrowsingUtils.jsm");
Cu.import("resource://gre/modules/SharedPromptUtils.jsm");
const { PromptUtils } = Cu.import("resource://gre/modules/SharedPromptUtils.jsm", {});
XPCOMUtils.defineLazyModuleGetter(this, "LoginHelper",
"resource://gre/modules/LoginHelper.jsm");

View File

@ -4,6 +4,7 @@
"../../../../testing/mochitest/chrome.eslintrc"
],
"rules": {
"no-undef": 0,
"no-unused-vars": 0,
},
}