Watch
1
0
Fork
You've already forked nexus
0
forked from Nexus/nexus

refactor and improve notification handling

This commit is contained in:
Henry Hiles 2026-10-19 21:04:28 -04:00
commit 765e96cce4
Signed by: Henry-Hiles
SSH key fingerprint: SHA256:VKQUdS31Q90KvX7EkKMHMBpUspcmItAh86a+v7PGiIs
2 changed files with 91 additions and 63 deletions

View file

@ -122,17 +122,21 @@ class UnifiedPushController extends AsyncNotifier<String?> {
: notification.eventId)
.hashCode &
0x7fffffff,
title: notification.roomName,
icon: icon,
payload: notification.eventRowId.toString(),
body: notification.text,
senderName: pmp?.name ?? notification.sender.name,
senderAvatar: senderAvatar,
selfName: notification.self.name,
isGroup: !notification.isDm,
sound: notification.sound,
timestamp: notification.timestamp,
threadId: notification.roomId,
title: notification.roomName,
body: notification.text,
payload: notification.eventRowId.toString(),
timestamp: notification.timestamp,
icon: icon,
sound: notification.sound,
message: (
sender: pmp == null
? notification.sender
: pmp.copyWith(id: "${notification.sender.id}/${pmp.id}"),
self: notification.self,
senderAvatar: senderAvatar,
isDm: notification.isDm,
),
);
if (isInBackground) exit(0);