feat: update user password
This commit is contained in:
parent
8e74712821
commit
3461d24bcd
|
|
@ -235,7 +235,9 @@ func (_i *usersService) SavePassword(req request.UserSavePassword, authToken str
|
||||||
if authToken != "" {
|
if authToken != "" {
|
||||||
createdBy := utilSvc.GetUserInfo(_i.Log, _i.Repo, authToken)
|
createdBy := utilSvc.GetUserInfo(_i.Log, _i.Repo, authToken)
|
||||||
|
|
||||||
err := _i.Keycloak.SetPassword(authToken, *createdBy.KeycloakId, req.Password)
|
tokenString := strings.TrimPrefix(authToken, "Bearer ")
|
||||||
|
|
||||||
|
err := _i.Keycloak.SetPassword(tokenString, *createdBy.KeycloakId, req.Password)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue