From 81d7ff3d69ae83a0305d71cedefea46d7fd149b1 Mon Sep 17 00:00:00 2001 From: Leufolium Date: Thu, 7 Nov 2024 18:50:24 +0800 Subject: [PATCH] 1 --- library/middleware/notif_sender.go | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/library/middleware/notif_sender.go b/library/middleware/notif_sender.go index 7d454509..f9c48f41 100644 --- a/library/middleware/notif_sender.go +++ b/library/middleware/notif_sender.go @@ -109,10 +109,12 @@ func InitNotifSender(_DefaultNotification *logic.Notification, _DefaultNotifBcst nids = append(nids, notification.GetId()) // 广播通知 - err = _DefaultNotifBcstCenter.BcstNotifs(ctx, nids, notification.GetObjType(), notification.ObjMids) - if err != nil { - logger.Error("通知广播失败:%v", err) - continue + if notification.GetPushTime() == consts.Notification_PushTime_Instant { + err = _DefaultNotifBcstCenter.BcstNotifs(ctx, nids, notification.GetObjType(), notification.ObjMids) + if err != nil { + logger.Error("通知广播失败:%v", err) + continue + } } }