diff --git a/src/models/user.go b/src/models/user.go index e6ea75a5..c7b7846f 100644 --- a/src/models/user.go +++ b/src/models/user.go @@ -95,7 +95,7 @@ func (u *User) Update(selectField interface{}, selectFields ...interface{}) erro return err } - return DB().Model(u).Select(selectField, selectFields).Updates(u).Error + return DB().Model(u).Select(selectField, selectFields...).Updates(u).Error } func (u *User) UpdateAllFields() error {