Abandons all storage initialisation routines if storage is disabled in config.

This commit is contained in:
emizzle 2018-06-26 14:18:55 +10:00
parent 0ba5f1a1b3
commit 6f539198da
1 changed files with 2 additions and 0 deletions

View File

@ -17,6 +17,8 @@ class Storage {
this._events = options.events;
this._logger = options.logger;
if(!this._storageConfig.enabled) return;
// filter list of dapp connections based on available_providers set in config
let hasSwarm = _.contains(this._storageConfig.available_providers, 'swarm'); // don't need to eval this in every loop iteration
// contains valid dapp storage providers