Subscription now will contains related_post meta

This commit is contained in:
LittleSheep 2025-02-25 23:55:13 +08:00
parent fd31120312
commit 94decc6bad

View File

@ -175,11 +175,16 @@ func NotifyUserSubscription(poster models.Publisher, item models.Post, content s
})
}
metadata := map[string]any{
"related_post": TruncatePostContent(item),
}
err := authkit.NotifyUserBatch(gap.Nx, userIDs, pushkit.Notification{
Topic: "interactive.subscription",
Title: nTitle,
Subtitle: nSubtitle,
Body: body,
Metadata: metadata,
Priority: 3,
})