diff --git a/app/user.go b/app/user.go index 6e12bda34b..d259439859 100644 --- a/app/user.go +++ b/app/user.go @@ -316,7 +316,11 @@ func (a *App) createUserOrGuest(c request.CTX, user *model.User, guest bool) (*m }, plugin.UserHasBeenCreatedID) }) - // Create/Update the subscriptionHistoryEvent + // For cloud yearly subscriptions, if the current user count of the workspace exceeds the number of seats initially purchased + // (plus the “threshold” of 10%), then a subscriptionHistoryEvent object would need to be created and added to the subscriptionHistory + // 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 {