feat: add sign-out redirect URL and enhance sign-in redirect handling

This commit is contained in:
Abhimanyu Saharan
2026-02-09 01:07:36 +05:30
parent 5630f9b8e8
commit e19e47106b
2 changed files with 4 additions and 3 deletions

View File

@@ -4,11 +4,10 @@ import sys
from logging.config import fileConfig from logging.config import fileConfig
from pathlib import Path from pathlib import Path
from alembic import context
from sqlalchemy import engine_from_config, pool from sqlalchemy import engine_from_config, pool
from sqlmodel import SQLModel from sqlmodel import SQLModel
from alembic import context
PROJECT_ROOT = Path(__file__).resolve().parents[1] PROJECT_ROOT = Path(__file__).resolve().parents[1]
if str(PROJECT_ROOT) not in sys.path: if str(PROJECT_ROOT) not in sys.path:
sys.path.append(str(PROJECT_ROOT)) sys.path.append(str(PROJECT_ROOT))

View File

@@ -26,7 +26,9 @@ describe("resolveSignInRedirectUrl", () => {
it("rejects protocol-relative urls", () => { it("rejects protocol-relative urls", () => {
vi.stubEnv("NEXT_PUBLIC_CLERK_SIGN_IN_FALLBACK_REDIRECT_URL", "/activity"); vi.stubEnv("NEXT_PUBLIC_CLERK_SIGN_IN_FALLBACK_REDIRECT_URL", "/activity");
expect(resolveSignInRedirectUrl("//evil.example.com/path")).toBe("/activity"); expect(resolveSignInRedirectUrl("//evil.example.com/path")).toBe(
"/activity",
);
}); });
it("rejects external absolute urls", () => { it("rejects external absolute urls", () => {