From 103d96dc81d6fd097fcdbed5bdd7487d7d73bf6e Mon Sep 17 00:00:00 2001 From: Mark Dietzer Date: Sun, 20 Sep 2020 05:47:37 -0700 Subject: [PATCH] fix(notification): wrong condition for sounds playing (#91) Co-authored-by: Jef LeCompte --- src/config.ts | 2 +- src/notification/notification.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/config.ts b/src/config.ts index 315601f36b..a37470edad 100644 --- a/src/config.ts +++ b/src/config.ts @@ -21,7 +21,7 @@ const notifications = { carrier: process.env.PHONE_CARRIER ?? '', number: process.env.PHONE_NUMBER ?? '' }, - playSound: process.env.PLAY_SOUND ?? 'false', + playSound: process.env.PLAY_SOUND ?? '', pushover: { token: process.env.PUSHOVER_TOKEN, user: process.env.PUSHOVER_USER diff --git a/src/notification/notification.ts b/src/notification/notification.ts index 28feaafa42..82a4c4f714 100644 --- a/src/notification/notification.ts +++ b/src/notification/notification.ts @@ -32,7 +32,7 @@ export function sendNotification(cartUrl: string) { sendPushoverNotification(cartUrl); } - if (notifications.playSound === 'true') { + if (notifications.playSound) { playSound(); } }