From 886a1f74e655468c1511ff029ff145b99404c20d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Oliveira?= Date: Thu, 24 Feb 2022 17:47:55 +0000 Subject: [PATCH] fix: wrong switch statement --- bin/lamassu-update-wallet-nodes | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/bin/lamassu-update-wallet-nodes b/bin/lamassu-update-wallet-nodes index f5f42d3a..e556b8b0 100644 --- a/bin/lamassu-update-wallet-nodes +++ b/bin/lamassu-update-wallet-nodes @@ -24,14 +24,7 @@ function plugin (crypto) { function isWalletNodeInstalled (status) { // From http://supervisord.org/subprocess.html#process-states - switch (status) { - case 'STARTING' || 'RUNNING' || 'STOPPED' || 'BACKOFF' || 'STOPPING' || 'EXITED' || 'FATAL': - return true - case 'UNKNOWN': - return false - default: - return false - } + return _.includes(status, ['STARTING', 'RUNNING', 'STOPPED', 'BACKOFF', 'STOPPING', 'EXITED', 'FATAL']) } function run () {