Browse Source

Silence or fix all linter errors, will address one by one.

1.1.101
Jorg Knobloch 2 years ago
parent
commit
5e187cd14a
10 changed files with 68 additions and 14 deletions
  1. +58
    -4
      .eslintrc.json
  2. +0
    -1
      chrome/bootstrap.js
  3. +0
    -1
      chrome/content/TbContacts.js
  4. +1
    -1
      chrome/content/TbHelper.js
  5. +1
    -1
      chrome/content/constants.js
  6. +1
    -0
      chrome/content/options.js
  7. +0
    -1
      chrome/content/pEpForThunderbird.js
  8. +0
    -2
      chrome/content/pEpMimeEncrypt.js
  9. +4
    -1
      chrome/content/pepmessengercompose.js
  10. +3
    -2
      chrome/content/pepmsghdrview.js

+ 58
- 4
.eslintrc.json View File

@ -7,8 +7,12 @@
"airbnb-base"
],
"globals": {
"Atomics": "readonly",
"SharedArrayBuffer": "readonly"
"ChromeUtils": "readonly",
"Components": "readonly",
"Ci": "readonly",
"Cc": "readonly",
"Cr": "readonly",
"Cu": "readonly"
},
"parserOptions": {
"ecmaVersion": 2018
@ -30,6 +34,56 @@
],
"quotes": [
"warn", "double"
]
],
"array-callback-return": "off",
"block-scoped-var": "off",
"camelcase": "off",
"class-methods-use-this": "off",
"comma-dangle": "off",
"curly": "off",
"default-case": "off",
"eqeqeq": "off",
"func-names": "off",
"function-paren-newline": "off",
"global-require": "off",
"guard-for-in": "off",
"implicit-arrow-linebreak": "off",
"indent": "off",
"lines-between-class-members": "off",
"max-classes-per-file": "off",
"max-len": "off",
"new-cap": "off",
"no-bitwise": "off",
"no-console": "off",
"no-empty": "off",
"no-empty-function": "off",
"no-fallthrough": "off",
"no-inner-declarations": "off",
"no-multi-spaces": "off",
"no-param-reassign": "off",
"no-plusplus": "off",
"no-prototype-builtins": "off",
"no-restricted-syntax": "off",
"no-return-assign": "off",
"no-return-await": "off",
"no-shadow": "off",
"no-underscore-dangle": "off",
"no-unreachable": "off",
"no-unused-expressions": "off",
"no-unused-vars": "off",
"no-use-before-define": "off",
"no-useless-constructor": "off",
"no-var": "off",
"nonblock-statement-body-position": "off",
"object-curly-spacing": "off",
"object-shorthand": "off",
"operator-linebreak": "off",
"prefer-const": "off",
"prefer-destructuring": "off",
"prefer-promise-reject-errors": "off",
"prefer-rest-params": "off",
"prefer-template": "off",
"space-unary-ops": "off",
"vars-on-top": "off"
}
}
}

+ 0
- 1
chrome/bootstrap.js View File

@ -1,4 +1,3 @@
/* globals Services */
/* exported install, uninstall, startup, shutdown */
var {Services} = ChromeUtils.import("resource://gre/modules/Services.jsm");
var {ExtensionSupport} = ChromeUtils.import("resource:///modules/ExtensionSupport.jsm");


+ 0
- 1
chrome/content/TbContacts.js View File

@ -1,4 +1,3 @@
var {Services} = ChromeUtils.import("resource://gre/modules/Services.jsm");
var {MailServices} = ChromeUtils.import("resource:///modules/MailServices.jsm");
var {pEp} = ChromeUtils.import("resource://pEp4Tb/content/modules/pEp.js");


+ 1
- 1
chrome/content/TbHelper.js View File

@ -122,7 +122,7 @@ const TbHelper = {
msgFolder.deleteMessages(msgArray, null, true, false, null, false);
} catch (ex) {}
try {
tempfile.remove();
tempFile.remove();
} catch (ex) {}
},
};


+ 1
- 1
chrome/content/constants.js View File

@ -1,4 +1,4 @@
/* eslint no-unused-vars:1 */
/* eslint no-unused-vars: "off" */
const ENV_PEPHOME = "PEPHOME";
const ENV_HOME = "HOME";
const ENV_APPDATA = "LocalAppData";


+ 1
- 0
chrome/content/options.js View File

@ -1,3 +1,4 @@
/* global Preferences */
var { MailServices } = ChromeUtils.import("resource:///modules/MailServices.jsm");
var { fixIterator } = ChromeUtils.import("resource:///modules/iteratorUtils.jsm");
var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");


+ 0
- 1
chrome/content/pEpForThunderbird.js View File

@ -1,4 +1,3 @@
/* global ChromeUtils */
var {pEp} = ChromeUtils.import("resource://pEp4Tb/content/modules/pEp.js");
var {pEpFactory} = ChromeUtils.import("resource://pEp4Tb/content/pEpFactory.js");
var {pEpMimeDecrypt} = ChromeUtils.import("resource://pEp4Tb/content/pEpMimeDecrypt.js");


+ 0
- 2
chrome/content/pEpMimeEncrypt.js View File

@ -1,5 +1,3 @@
/* global gPgpMimeObj, Components, ChromeUtils */
var {pEp} = ChromeUtils.import("resource://pEp4Tb/content/modules/pEp.js");
var {TbContacts} = ChromeUtils.import("resource://pEp4Tb/content/TbContacts.js");


+ 4
- 1
chrome/content/pepmessengercompose.js View File

@ -1,4 +1,5 @@
/* global gCurrentIdentity, gMsgCompose, ChromeUtils, Cc, Ci, Recipients2CompFields, Services */
/* global gCurrentIdentity, gMsgCompose, Recipients2CompFields */
/* global onRecipientsChanged, onAddressColCommand */
var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
var {pEpController} = ChromeUtils.import("resource://pEp4Tb/content/pEpController.js");
var {Handshake} = ChromeUtils.import("resource://pEp4Tb/content/modules/handshake.js");
@ -177,6 +178,7 @@ var pEpComposer = {
// Monkey patching onRecipientsChanged event to add some pEp functionality.
const tb_onRecipientsChanged = onRecipientsChanged;
// eslint-disable-next-line no-global-assign
onRecipientsChanged = (aAutomatic) => {
that.pEp_onRecipientsChanged();
tb_onRecipientsChanged(aAutomatic);
@ -192,6 +194,7 @@ var pEpComposer = {
// Monkey patching onAddressColCommand event to add some pEp functionality.
if (typeof(onAddressColCommand) == "function") { // Only exists in TB 68.
const tb_onAddressColCommand = onAddressColCommand;
// eslint-disable-next-line no-global-assign
onAddressColCommand = (aAddressWidgetId) => {
that.pEp_onRecipientsChanged();
tb_onAddressColCommand(aAddressWidgetId);


+ 3
- 2
chrome/content/pepmsghdrview.js View File

@ -1,4 +1,4 @@
/* global gFolderDisplay, gDBView, Cc, Ci, ChromeUtils */
/* global gFolderDisplay, gDBView */
var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
const {pEpController} = ChromeUtils.import("resource://pEp4Tb/content/pEpController.js");
var {pEpUtils} = ChromeUtils.import("resource://pEp4Tb/content/modules/utils.js");
@ -6,6 +6,7 @@ var {TbHelper} = ChromeUtils.import("resource://pEp4Tb/content/TbHelper.js");
var {TbMessageView} = ChromeUtils.import("resource://pEp4Tb/content/TbMessageView.js");
var {TbContacts} = ChromeUtils.import("resource://pEp4Tb/content/TbContacts.js");
var { MailServices } = ChromeUtils.import("resource:///modules/MailServices.jsm");
var { fixIterator } = ChromeUtils.import("resource:///modules/iteratorUtils.jsm");
const PEP_COLUMN_NAME = "pEpStatusCol";
@ -306,6 +307,6 @@ function storeDecryptedCopy(msgHdr, mimeMessage) {
break;
}
}
};
}
pEpHdrView.init();

Loading…
Cancel
Save