webpush: don't notify author about own events

This commit is contained in:
Alex Gleason
2024-10-14 17:31:05 -05:00
parent a7d8d86fa7
commit 4c5d98f402

View File

@@ -252,6 +252,10 @@ async function webPush(event: NostrEvent): Promise<void> {
.execute();
for (const row of rows) {
if (row.pubkey === event.pubkey) {
continue; // Don't notify authors about their own events.
}
const notification = await renderNotification(event, { viewerPubkey: row.pubkey });
if (!notification) {
continue;