Merge commit from fork
* Harden user setting cache updates * Fix user update test isolation
This commit is contained in:
@@ -89,8 +89,7 @@ func UpdateSubscriptionPreference(c *gin.Context) {
|
||||
}
|
||||
current := user.GetSetting()
|
||||
current.BillingPreference = pref
|
||||
user.SetSetting(current)
|
||||
if err := user.Update(false); err != nil {
|
||||
if err := model.UpdateUserSetting(user.Id, current); err != nil {
|
||||
common.ApiError(c, err)
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user