Remove useAssume from layouts now that we have the /assume page that redirects

Signed-off-by: Émile Ré <emile@getprobo.com>
This commit is contained in:
Émile Ré
2026-02-10 18:12:20 +04:00
parent 260f196f9c
commit 795b0a8de2
6 changed files with 16 additions and 29 deletions

View File

@@ -11,7 +11,7 @@ export function OrganizationErrorBoundary() {
const search = new URLSearchParams([
["organization-id", organizationId],
["redirect-path", window.location.href],
["redirect-path", window.location.pathname + window.location.search],
]);
if (error instanceof UnAuthenticatedError) {

View File

@@ -6,7 +6,9 @@ import { PageError } from "./PageError";
export function RootErrorBoundary() {
const error = useRouteError();
const search = new URLSearchParams([["redirect-path", window.location.href]]);
const search = new URLSearchParams([
["redirect-path", window.location.pathname + window.location.search],
]);
if (error instanceof UnAuthenticatedError) {
return <Navigate to={{ pathname: "/auth/login", search: "?" + search.toString() }} />;