From 52cd84debcc514d97aa66c51d5981650b5c8b7fa Mon Sep 17 00:00:00 2001 From: Michal Date: Wed, 24 Apr 2024 21:11:20 +0000 Subject: [PATCH] feat: switched to OTP auth first --- cypress/e2e/auth.cy.ts | 2 +- src/router/gates/auth.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cypress/e2e/auth.cy.ts b/cypress/e2e/auth.cy.ts index 7b32059..5cf2b9f 100644 --- a/cypress/e2e/auth.cy.ts +++ b/cypress/e2e/auth.cy.ts @@ -742,7 +742,7 @@ describe("Confirm email", () => { it("Redirects to login when unauthenticated", () => { cy.visit("/confirm-email"); - cy.location("pathname").should("eq", "/login"); + cy.location("pathname").should("eq", "/login/otp"); // There should be a query param of redirect pointing to /confirm-email cy.location("search").should("eq", "?redirect=/confirm-email"); }); diff --git a/src/router/gates/auth.ts b/src/router/gates/auth.ts index c1341be..c9b5921 100644 --- a/src/router/gates/auth.ts +++ b/src/router/gates/auth.ts @@ -17,7 +17,7 @@ export default class extends baseGate { route(): false | RouteLocationRaw { // If the route was supposed to be login-otp, we should redirect to login-otp, else just login return { - name: "login", + name: "login/otp", }; } }