fix: notifier groups cache not initialized (#995)

This commit is contained in:
UUBulb
2025-02-17 20:14:38 +08:00
committed by GitHub
parent 65f9db7d5a
commit 029d6dbd5f
2 changed files with 7 additions and 0 deletions

View File

@@ -163,6 +163,7 @@ func batchDeleteNotification(c *gin.Context) (any, error) {
for _, nid := range n {
if ns, ok := singleton.NotificationMap[nid]; ok {
if !ns.HasPermission(c) {
singleton.NotificationsLock.RUnlock()
return nil, singleton.Localizer.ErrorT("permission denied")
}
}