From de901b73fc8f384d08459a3229bb570f7387c852 Mon Sep 17 00:00:00 2001 From: Pascal Precht Date: Thu, 11 Oct 2018 12:25:09 +0200 Subject: [PATCH] chore(modules/storage): make process launcher callback optional We aren't always interested in calling a function after the storage process has been launched, so passing a callback should be optional. --- lib/modules/storage/storageProcessesLauncher.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/modules/storage/storageProcessesLauncher.js b/lib/modules/storage/storageProcessesLauncher.js index d0220634..4d89b385 100644 --- a/lib/modules/storage/storageProcessesLauncher.js +++ b/lib/modules/storage/storageProcessesLauncher.js @@ -86,6 +86,8 @@ class StorageProcessesLauncher { launchProcess(storageName, callback) { const self = this; + callback = callback || function () {}; + if (self.processes[storageName]) { return callback(__('Storage process already started')); }