Fix registration not logging you into the new account
This commit is contained in:
@@ -80,11 +80,7 @@ export const RegisterPage: FC = () => {
|
|||||||
passwordlessUser
|
passwordlessUser
|
||||||
);
|
);
|
||||||
|
|
||||||
if (!client || !client.groupCallEventHandler || !setClient) {
|
if (client && client?.groupCallEventHandler && passwordlessUser) {
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (passwordlessUser) {
|
|
||||||
// Migrate the user's rooms
|
// Migrate the user's rooms
|
||||||
for (const groupCall of client.groupCallEventHandler.groupCalls.values()) {
|
for (const groupCall of client.groupCallEventHandler.groupCalls.values()) {
|
||||||
const roomId = groupCall.room.roomId;
|
const roomId = groupCall.room.roomId;
|
||||||
@@ -107,7 +103,7 @@ export const RegisterPage: FC = () => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
setClient({ client: newClient, session });
|
setClient?.({ client: newClient, session });
|
||||||
PosthogAnalytics.instance.eventSignup.cacheSignupEnd(new Date());
|
PosthogAnalytics.instance.eventSignup.cacheSignupEnd(new Date());
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user