From 12ddf6143685ea9414bfef1a03fe7ed40f9ad145 Mon Sep 17 00:00:00 2001 From: Mark Qvist Date: Sun, 8 Sep 2024 15:17:26 +0200 Subject: [PATCH] Disable notifications in daemon mode --- sbapp/sideband/core.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/sbapp/sideband/core.py b/sbapp/sideband/core.py index 9b5ae11..1348aec 100644 --- a/sbapp/sideband/core.py +++ b/sbapp/sideband/core.py @@ -864,12 +864,13 @@ class SidebandCore(): RNS.log("Error while setting LXMF propagation node: "+str(e), RNS.LOG_ERROR) def notify(self, title, content, group=None, context_id=None): - if RNS.vendor.platformutils.is_linux(): - from sbapp.ui.helpers import strip_emojis - title = strip_emojis(title) - content = strip_emojis(content) - if not self.is_daemon: + if RNS.vendor.platformutils.is_linux(): + from sbapp.ui.helpers import strip_emojis + title = strip_emojis(title) + content = strip_emojis(content) + + if self.config["notifications_on"]: if RNS.vendor.platformutils.is_android(): if self.getpersistent("permissions.notifications"):