From 12e1d6466067b0b3428c226fa65e9c1566a2308d Mon Sep 17 00:00:00 2001 From: Benjamin Palko Date: Mon, 25 Aug 2025 16:47:06 -0400 Subject: [PATCH] fix null items and log if event is null --- services/Notifications.qml | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/services/Notifications.qml b/services/Notifications.qml index d15e035..7d3f064 100644 --- a/services/Notifications.qml +++ b/services/Notifications.qml @@ -1,5 +1,6 @@ pragma Singleton +import QtQuick import Quickshell import Quickshell.Services.Notifications @@ -31,9 +32,14 @@ Singleton { if (!root.enabled) { return; } + + if (event == null) { + console.log("Event is null?"); + return; + } + event.tracked = true; - root.list = root.list.filter(item => item.id != event.id); - root.list.push(event); + root.list = root.list.filter(item => item != null && item.id != event.id).push(event); } } }