💥 fix: can't convert non-null pointer to js value

Thanks aylur!!
This commit is contained in:
retrozinndev
2025-08-11 12:38:59 -03:00
parent e82eebca91
commit 7bd159ff10
13 changed files with 120 additions and 61 deletions
+5 -4
View File
@@ -32,10 +32,11 @@ export function NotificationWidget({ notification, actionClicked, holdOnHover, s
AstalNotifd.get_default().get_notification(notification)
: notification;
const actions: Array<AstalNotifd.Action>|undefined = (notification instanceof AstalNotifd.Notification) ?
notification.actions?.filter(a =>
a.id.toLowerCase() !== "view" && a.label.toLowerCase() != "view"
)
const actions: Array<AstalNotifd.Action>|undefined = ((notification instanceof AstalNotifd.Notification) &&
notification.actions && notification.actions.filter(a => Boolean(a)).length > 0) ?
notification.actions?.filter(a =>
a?.id?.toLowerCase() !== "view" && a?.label?.toLowerCase() != "view"
)
: undefined;
const conns: Map<GObject.Object, Array<number>> = new Map();