[MM-48973] Enable test that was fixed separately (#22043)
* Enable test that was fixed separately * Add cloud check to be safe * Feedback Co-authored-by: Mattermost Build <build@mattermost.com>
Этот коммит содержится в:
@@ -102,7 +102,6 @@ func TestAddUserToTeam(t *testing.T) {
|
||||
})
|
||||
|
||||
t.Run("block user by domain but allow bot", func(t *testing.T) {
|
||||
t.Skip("MM-48973")
|
||||
th.BasicTeam.AllowedDomains = "example.com"
|
||||
_, err := th.App.UpdateTeam(th.BasicTeam)
|
||||
require.Nil(t, err, "Should update the team")
|
||||
|
||||
14
app/user.go
14
app/user.go
@@ -321,12 +321,14 @@ func (a *App) createUserOrGuest(c request.CTX, user *model.User, guest bool) (*m
|
||||
// table in CWS. This is then used to calculate how much the customers have to pay in addition for the extra users. If the
|
||||
// workspace is currently on a monthly plan, then this function will not do anything.
|
||||
|
||||
go func() {
|
||||
_, err := a.SendSubscriptionHistoryEvent(ruser.Id)
|
||||
if err != nil {
|
||||
c.Logger().Error("Failed to create/update the SubscriptionHistoryEvent", mlog.Err(err))
|
||||
}
|
||||
}()
|
||||
if a.Channels().License().IsCloud() {
|
||||
go func(userId string) {
|
||||
_, err := a.SendSubscriptionHistoryEvent(userId)
|
||||
if err != nil {
|
||||
c.Logger().Error("Failed to create/update the SubscriptionHistoryEvent", mlog.Err(err))
|
||||
}
|
||||
}(ruser.Id)
|
||||
}
|
||||
|
||||
return ruser, nil
|
||||
}
|
||||
|
||||
Ссылка в новой задаче
Block a user