Signed-off-by: Seongmin Lee git@boltless.me
+7
appview/notify/db/db.go
+7
appview/notify/db/db.go
···
13
13
"tangled.org/core/idresolver"
14
14
)
15
15
16
+
const (
17
+
maxMentions = 5
18
+
)
19
+
16
20
type databaseNotifier struct {
17
21
db *db.DB
18
22
res *idresolver.Resolver
···
421
425
issueId *int64,
422
426
pullId *int64,
423
427
) {
428
+
if eventType == models.NotificationTypeUserMentioned && len(recipients) > maxMentions {
429
+
recipients = recipients[:maxMentions]
430
+
}
424
431
recipientSet := make(map[syntax.DID]struct{})
425
432
for _, did := range recipients {
426
433
// everybody except actor themselves