summaryrefslogtreecommitdiff
path: root/bin/manage_users
diff options
context:
space:
mode:
authorDaan Sprenkels2019-01-10 14:01:14 +0100
committerDaan Sprenkels2019-01-10 14:05:12 +0100
commit7c144ac7a99b806b55aed1810cfa434318f073ec (patch)
treee7e2c407c39dd2715c2a5a5010ac9690ca5e66b9 /bin/manage_users
parent4eb7748adb943005b953648c6dcad1f898600816 (diff)
Fix broken manage_users after Winston upgrade
Commit c3584770 upgrades Winston and with that version `logger.transports.console` becomes undefined. This commit updates the code to prevent the crash. Signed-off-by: Daan Sprenkels <hello@dsprenkels.com>
Diffstat (limited to '')
-rwxr-xr-xbin/manage_users2
1 files changed, 1 insertions, 1 deletions
diff --git a/bin/manage_users b/bin/manage_users
index 8c356200..f744150d 100755
--- a/bin/manage_users
+++ b/bin/manage_users
@@ -2,7 +2,7 @@
// First configure the logger so it does not spam the console
const logger = require("../lib/logger");
-logger.transports.console.level = "warning";
+logger.transports.forEach((transport) => transport.level = "warning")
const models = require("../lib/models/");
const readline = require("readline-sync");