feat: accounts app passkeys login
This commit is contained in:
parent
159521b8d2
commit
3f7a66682f
2 changed files with 7 additions and 7 deletions
6
apps/accounts/src/pages/passkeys/finish.tsx
Normal file
6
apps/accounts/src/pages/passkeys/finish.tsx
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
import PasskeysFinishPage from '@ente/accounts/pages/passkeys/finish';
|
||||||
|
const PasskeysFinish = () => {
|
||||||
|
return <PasskeysFinishPage />;
|
||||||
|
};
|
||||||
|
|
||||||
|
export default PasskeysFinish;
|
|
@ -31,15 +31,9 @@ const PasskeysFlow = () => {
|
||||||
// get redirect from the query params
|
// get redirect from the query params
|
||||||
const redirect = searchParams.get('redirect');
|
const redirect = searchParams.get('redirect');
|
||||||
|
|
||||||
if (!redirect) {
|
|
||||||
setInvalidInfo(true);
|
|
||||||
setLoading(false);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
const redirectURL = new URL(redirect);
|
const redirectURL = new URL(redirect);
|
||||||
if (process.env.NEXT_PUBLIC_DISABLE_REDIRECT_CHECK !== 'true') {
|
if (process.env.NEXT_PUBLIC_DISABLE_REDIRECT_CHECK !== 'true') {
|
||||||
if (!redirectURL.host.endsWith('ente.io')) {
|
if (redirect !== '' && !redirectURL.host.endsWith('ente.io')) {
|
||||||
setInvalidInfo(true);
|
setInvalidInfo(true);
|
||||||
setLoading(false);
|
setLoading(false);
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Add table
Reference in a new issue