From f44a75d2257fdaa1ba46bc246b48f84b89978c1b Mon Sep 17 00:00:00 2001 From: LittleSheep Date: Sun, 9 Jun 2024 13:08:13 +0800 Subject: [PATCH] :bug: Bug fixes --- pkg/services/messages.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkg/services/messages.go b/pkg/services/messages.go index 751994f..a0ece7c 100644 --- a/pkg/services/messages.go +++ b/pkg/services/messages.go @@ -86,7 +86,9 @@ func NewMessage(message models.Message) (models.Message, error) { message, _ = GetMessage(message.Channel, message.ID) for _, member := range members { doesNotify := true - if member.ID != message.Sender.ID { + if member.ID == message.SenderID { + doesNotify = false + } else { switch member.Notify { case models.NotifyLevelNone: doesNotify = false @@ -105,8 +107,6 @@ func NewMessage(message models.Message) (models.Message, error) { default: break } - } else { - doesNotify = false } if doesNotify {