From 11eb6c29d4bc92ed56628269ac03814bd68f8b02 Mon Sep 17 00:00:00 2001 From: Francis Lachapelle Date: Wed, 24 Nov 2021 10:41:02 -0500 Subject: [PATCH] fix(mail(js)): don't poll server from popup windows --- UI/WebServerResources/js/Common/navController.js | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/UI/WebServerResources/js/Common/navController.js b/UI/WebServerResources/js/Common/navController.js index d1cadd48e..fb66425e9 100644 --- a/UI/WebServerResources/js/Common/navController.js +++ b/UI/WebServerResources/js/Common/navController.js @@ -50,14 +50,16 @@ // Listen to HTTP errors broadcasted from HTTP interceptor $rootScope.$on('http:Error', onHttpError); - if (sgSettings.activeUser('path').calendar) { - // Fetch Calendar alarms - Preferences.getAlarms(); - } + if (!isPopup) { + if (sgSettings.activeUser('path').calendar) { + // Fetch Calendar alarms + Preferences.getAlarms(); + } - if (sgSettings.activeUser('path').mail) { - // Poll inbox for new messages - Preferences.pollInbox(); + if (sgSettings.activeUser('path').mail) { + // Poll inbox for new messages + Preferences.pollInbox(); + } } };