From 5a658429f6c465024ff8032e18fd92b6c0dca5d7 Mon Sep 17 00:00:00 2001 From: Renato Becker Date: Tue, 8 Sep 2020 17:35:29 -0300 Subject: [PATCH] Fix omnichannel service status changing when server starts. --- ee/app/livechat-enterprise/server/startup.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ee/app/livechat-enterprise/server/startup.js b/ee/app/livechat-enterprise/server/startup.js index e9615a5735df..cda5f67331ee 100644 --- a/ee/app/livechat-enterprise/server/startup.js +++ b/ee/app/livechat-enterprise/server/startup.js @@ -31,7 +31,9 @@ Meteor.startup(async function() { }); settings.onload('Livechat_business_hour_type', (_, value) => { businessHourManager.registerBusinessHourBehavior(businessHours[value]); - businessHourManager.startManager(); + if (settings.get('Livechat_enable_business_hours')) { + businessHourManager.startManager(); + } }); await resetDefaultBusinessHourIfNeeded(); });