Fix safe ssoLoginURL params after activation + resolver error
Signed-off-by: Émile Ré <emile@getprobo.com>
This commit is contained in:
@@ -76,7 +76,7 @@ export default function ActivateAccountPage() {
|
|||||||
|
|
||||||
if (activateAccount.ssoLoginUrl) {
|
if (activateAccount.ssoLoginUrl) {
|
||||||
const url = new URL(activateAccount.ssoLoginUrl);
|
const url = new URL(activateAccount.ssoLoginUrl);
|
||||||
url.search = searchParams.toString();
|
url.searchParams.set("continue", safeContinueUrl.toString());
|
||||||
|
|
||||||
window.location.href = url.toString();
|
window.location.href = url.toString();
|
||||||
return;
|
return;
|
||||||
|
|||||||
@@ -427,7 +427,8 @@ func (r *mutationResolver) ActivateAccount(ctx context.Context, input types.Acti
|
|||||||
if identity.HashedPassword == nil {
|
if identity.HashedPassword == nil {
|
||||||
token, err := r.iam.AuthService.GetResetPasswordToken(ctx, identity.EmailAddress)
|
token, err := r.iam.AuthService.GetResetPasswordToken(ctx, identity.EmailAddress)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, fmt.Errorf("cannot generate password create token: %w", err)
|
r.logger.ErrorCtx(ctx, "cannot generate password create token", log.Error(err))
|
||||||
|
return nil, gqlutils.Internal(ctx)
|
||||||
}
|
}
|
||||||
|
|
||||||
createPasswordToken = &token
|
createPasswordToken = &token
|
||||||
|
|||||||
Reference in New Issue
Block a user