Ensure users status is set to offline when deactivated (#30900)

Этот коммит содержится в:
Daniel Espino García
2025-05-29 10:41:14 +02:00
коммит произвёл GitHub
родитель 79bf1c34db
Коммит 293f38ad0b
11 изменённых файлов: 141 добавлений и 16 удалений

Просмотреть файл

@@ -2440,7 +2440,7 @@ func TestUserAllowsEmail(t *testing.T) {
t.Run("should return true", func(t *testing.T) {
user := th.CreateUser()
th.App.SetStatusOffline(user.Id, true)
th.App.SetStatusOffline(user.Id, true, false)
channelMemberNotificationProps := model.StringMap{
model.EmailNotifyProp: model.ChannelNotifyDefault,
@@ -2466,7 +2466,7 @@ func TestUserAllowsEmail(t *testing.T) {
t.Run("should return false in case the EMAIL_NOTIFY_PROP is false", func(t *testing.T) {
user := th.CreateUser()
th.App.SetStatusOffline(user.Id, true)
th.App.SetStatusOffline(user.Id, true, false)
channelMemberNotificationProps := model.StringMap{
model.EmailNotifyProp: "false",
@@ -2479,7 +2479,7 @@ func TestUserAllowsEmail(t *testing.T) {
t.Run("should return false in case the MARK_UNREAD_NOTIFY_PROP is CHANNEL_MARK_UNREAD_MENTION", func(t *testing.T) {
user := th.CreateUser()
th.App.SetStatusOffline(user.Id, true)
th.App.SetStatusOffline(user.Id, true, false)
channelMemberNotificationProps := model.StringMap{
model.EmailNotifyProp: model.ChannelNotifyDefault,
@@ -2492,7 +2492,7 @@ func TestUserAllowsEmail(t *testing.T) {
t.Run("should return false in case the Post type is POST_AUTO_RESPONDER", func(t *testing.T) {
user := th.CreateUser()
th.App.SetStatusOffline(user.Id, true)
th.App.SetStatusOffline(user.Id, true, false)
channelMemberNotificationProps := model.StringMap{
model.EmailNotifyProp: model.ChannelNotifyDefault,