Bug 1561435 - Fix linting errors for services/, r=standard8

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D35931

--HG--
extra : source : f441e31c307bc815c7f05e99c0cd8ee77344dc80
extra : intermediate-source : 7e366ab79479e3a9bbdf9e61f04cfa7b6c271990
This commit is contained in:
Victor Porof 2019-06-21 13:38:54 -07:00
parent 9d673f1f0f
commit 34c33b48c4
10 changed files with 15 additions and 9 deletions

View file

@ -13,14 +13,17 @@ const { Async } = ChromeUtils.import("resource://services-common/async.js");
// https://github.com/mozilla/fxa-auth-server/wiki/onepw-protocol#wiki-use-session-certificatesign-etc // https://github.com/mozilla/fxa-auth-server/wiki/onepw-protocol#wiki-use-session-certificatesign-etc
var SESSION_KEYS = { var SESSION_KEYS = {
sessionToken: h( sessionToken: h(
// eslint-disable-next-line no-useless-concat
"a0a1a2a3a4a5a6a7 a8a9aaabacadaeaf" + "b0b1b2b3b4b5b6b7 b8b9babbbcbdbebf" "a0a1a2a3a4a5a6a7 a8a9aaabacadaeaf" + "b0b1b2b3b4b5b6b7 b8b9babbbcbdbebf"
), ),
tokenID: h( tokenID: h(
// eslint-disable-next-line no-useless-concat
"c0a29dcf46174973 da1378696e4c82ae" + "10f723cf4f4d9f75 e39f4ae3851595ab" "c0a29dcf46174973 da1378696e4c82ae" + "10f723cf4f4d9f75 e39f4ae3851595ab"
), ),
reqHMACkey: h( reqHMACkey: h(
// eslint-disable-next-line no-useless-concat
"9d8f22998ee7f579 8b887042466b72d5" + "3e56ab0c094388bf 65831f702d2febc0" "9d8f22998ee7f579 8b887042466b72d5" + "3e56ab0c094388bf 65831f702d2febc0"
), ),
}; };

View file

@ -360,7 +360,7 @@ TokenServerClient.prototype = {
for (let k of ["id", "key", "api_endpoint", "uid", "duration"]) { for (let k of ["id", "key", "api_endpoint", "uid", "duration"]) {
if (!(k in result)) { if (!(k in result)) {
let error = new TokenServerClientServerError( let error = new TokenServerClientServerError(
"Expected key not " + " present in result: " + k "Expected key not present in result: " + k
); );
error.cause = "malformed-response"; error.cause = "malformed-response";
error.response = response; error.response = response;

View file

@ -13,6 +13,7 @@ const FAKE_SESSION_TOKEN =
// https://wiki.mozilla.org/Identity/AttachedServices/KeyServerProtocol#.2Faccount.2Fkeys // https://wiki.mozilla.org/Identity/AttachedServices/KeyServerProtocol#.2Faccount.2Fkeys
var ACCOUNT_KEYS = { var ACCOUNT_KEYS = {
keyFetch: h( keyFetch: h(
// eslint-disable-next-line no-useless-concat
"8081828384858687 88898a8b8c8d8e8f" + "9091929394959697 98999a9b9c9d9e9f" "8081828384858687 88898a8b8c8d8e8f" + "9091929394959697 98999a9b9c9d9e9f"
), ),
@ -26,10 +27,12 @@ var ACCOUNT_KEYS = {
), ),
kA: h( kA: h(
// eslint-disable-next-line no-useless-concat
"2021222324252627 28292a2b2c2d2e2f" + "3031323334353637 38393a3b3c3d3e3f" "2021222324252627 28292a2b2c2d2e2f" + "3031323334353637 38393a3b3c3d3e3f"
), ),
wrapKB: h( wrapKB: h(
// eslint-disable-next-line no-useless-concat
"4041424344454647 48494a4b4c4d4e4f" + "5051525354555657 58595a5b5c5d5e5f" "4041424344454647 48494a4b4c4d4e4f" + "5051525354555657 58595a5b5c5d5e5f"
), ),
}; };

View file

@ -331,7 +331,7 @@ AddonUtilsInternal.prototype = {
// add-ons without a sourceURI. // add-ons without a sourceURI.
if (!addon.sourceURI) { if (!addon.sourceURI) {
this._log.info( this._log.info(
"Skipping install of add-on because missing " + "sourceURI: " + addon.id "Skipping install of add-on because missing sourceURI: " + addon.id
); );
return false; return false;
} }

View file

@ -1732,7 +1732,7 @@ SyncEngine.prototype = {
// are the same, does it matter? // are the same, does it matter?
if (recordsEqual) { if (recordsEqual) {
this._log.trace( this._log.trace(
"Ignoring incoming item because the local item is " + "identical." "Ignoring incoming item because the local item is identical."
); );
this._modified.delete(item.id); this._modified.delete(item.id);

View file

@ -643,7 +643,7 @@ AddonsStore.prototype = {
if (!result) { if (!result) {
this._log.debug( this._log.debug(
addon.id + " not syncable: add-on not found in add-on " + "repository." addon.id + " not syncable: add-on not found in add-on repository."
); );
return false; return false;
} }

View file

@ -368,7 +368,7 @@ BaseBookmarksEngine.prototype = {
let shouldWipeRemote = await PlacesSyncUtils.bookmarks.shouldWipeRemote(); let shouldWipeRemote = await PlacesSyncUtils.bookmarks.shouldWipeRemote();
if (!shouldWipeRemote) { if (!shouldWipeRemote) {
this._log.debug( this._log.debug(
"Checking if server sync ID ${newSyncID} matches " + "existing", "Checking if server sync ID ${newSyncID} matches existing",
{ newSyncID } { newSyncID }
); );
await this._ensureCurrentSyncID(newSyncID); await this._ensureCurrentSyncID(newSyncID);
@ -907,7 +907,7 @@ BufferedBookmarksEngine.prototype = {
let change = this._modified.changes[id]; let change = this._modified.changes[id];
if (!change) { if (!change) {
this._log.error( this._log.error(
"Creating record for item ${id} not in strong " + "changeset", "Creating record for item ${id} not in strong changeset",
{ id } { id }
); );
throw new TypeError("Can't create record for unchanged item"); throw new TypeError("Can't create record for unchanged item");

View file

@ -169,7 +169,7 @@ BulkKeyBundle.prototype = {
set keyPairB64(value) { set keyPairB64(value) {
if (!Array.isArray(value) || value.length != 2) { if (!Array.isArray(value) || value.length != 2) {
throw new Error( throw new Error(
"BulkKeyBundle.keyPairB64 value must be an array of 2 " + "keys." "BulkKeyBundle.keyPairB64 value must be an array of 2 keys."
); );
} }

View file

@ -1143,7 +1143,7 @@ Sync11Service.prototype = {
this.status.sync = METARECORD_DOWNLOAD_FAIL; this.status.sync = METARECORD_DOWNLOAD_FAIL;
this.errorHandler.checkServerError(this.recordManager.response); this.errorHandler.checkServerError(this.recordManager.response);
this._log.warn( this._log.warn(
"Unknown error while downloading metadata record. " + "Aborting sync." "Unknown error while downloading metadata record. Aborting sync."
); );
return false; return false;
} }

View file

@ -187,7 +187,7 @@ EngineSynchronizer.prototype = {
// throwing an exception when trying to fetch metaURL. // throwing an exception when trying to fetch metaURL.
if (!this.service.clusterURL) { if (!this.service.clusterURL) {
this._log.debug( this._log.debug(
"Aborting sync, no cluster URL: " + "not uploading new meta/global." "Aborting sync, no cluster URL: not uploading new meta/global."
); );
return; return;
} }