From 2baa6ed792dbb255fa3ce6ca608da3f74f9aba6a Mon Sep 17 00:00:00 2001 From: Iuri Matias Date: Mon, 9 Jul 2018 01:21:27 +0300 Subject: [PATCH] make linter happy --- lib/core/logger.js | 6 +++--- lib/modules/ipfs/index.js | 4 ++-- lib/modules/swarm/index.js | 4 ++-- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/lib/core/logger.js b/lib/core/logger.js index f1011f8a0..758c3eaec 100644 --- a/lib/core/logger.js +++ b/lib/core/logger.js @@ -24,7 +24,7 @@ Logger.prototype.error = function () { return; } this.events.emit("log", "error", ...arguments); - this.logFunction(...Array.from(arguments).map(t => t ? t.red : t)); + this.logFunction(...Array.from(arguments).map(t => { return t ? t.red : t; })); this.writeToFile("[error]: ", ...arguments); }; @@ -33,7 +33,7 @@ Logger.prototype.warn = function () { return; } this.events.emit("log", "warning", ...arguments); - this.logFunction(...Array.from(arguments).map(t => t ? t.yellow : t)); + this.logFunction(...Array.from(arguments).map(t => { return t ? t.yellow : t; })); this.writeToFile("[warning]: ", ...arguments); }; @@ -42,7 +42,7 @@ Logger.prototype.info = function () { return; } this.events.emit("log", "info", ...arguments); - this.logFunction(...Array.from(arguments).map(t => t ? t.green : t)); + this.logFunction(...Array.from(arguments).map(t => { return t ? t.green : t; })); this.writeToFile("[info]: ", ...arguments); }; diff --git a/lib/modules/ipfs/index.js b/lib/modules/ipfs/index.js index 775756294..c0781b917 100644 --- a/lib/modules/ipfs/index.js +++ b/lib/modules/ipfs/index.js @@ -18,7 +18,7 @@ class IPFS { this.blockchainConfig = embark.config.blockchainConfig; if (!this.isIpfsEnabledInTheConfig()) { - return + return; } this.setServiceCheck(); @@ -132,7 +132,7 @@ class IPFS { } isIpfsEnabledInTheConfig() { - let { enabled, available_providers, dappConnection } = this.storageConfig; + let {enabled, available_providers, dappConnection} = this.storageConfig; return enabled && (available_providers.indexOf('ipfs') > 0 || dappConnection.find(c => c.provider === 'ipfs')); } diff --git a/lib/modules/swarm/index.js b/lib/modules/swarm/index.js index 46e1a24e1..00f3076e6 100644 --- a/lib/modules/swarm/index.js +++ b/lib/modules/swarm/index.js @@ -6,7 +6,7 @@ const StorageProcessesLauncher = require('../../processes/storageProcesses/stora class Swarm { - constructor(embark, options) { + constructor(embark, _options) { this.logger = embark.logger; this.events = embark.events; this.buildDir = embark.config.buildDir; @@ -108,7 +108,7 @@ class Swarm { } isSwarmEnabledInTheConfig() { - let { enabled, available_providers, dappConnection } = this.storageConfig; + let {enabled, available_providers, dappConnection} = this.storageConfig; return enabled && (available_providers.indexOf('swarm') > 0 || dappConnection.find(c => c.provider === 'swarm')); }