update keycloak signup / login
This commit is contained in:
@@ -9,7 +9,13 @@ export function useSignInWithProvider() {
|
||||
const mutationKey = ['auth', 'sign-in-with-provider'];
|
||||
|
||||
const mutationFn = async (credentials: SignInWithOAuthCredentials) => {
|
||||
const response = await client.auth.signInWithOAuth(credentials);
|
||||
const response = await client.auth.signInWithOAuth({
|
||||
...credentials,
|
||||
options: {
|
||||
...credentials.options,
|
||||
redirectTo: `${window.location.origin}/auth/callback`,
|
||||
},
|
||||
});
|
||||
|
||||
if (response.error) {
|
||||
throw response.error.message;
|
||||
|
||||
Reference in New Issue
Block a user