app/routes/admin.logout.tsx
15 lines and 2 functions in DrDustinEdwards/dustinedwards-info, at commit 1590ba4 on 2026-10-24. This file on GitHub.
Functions
| Function | Lines | Complexity | Covered | CRAP | Mutation |
|---|---|---|---|---|---|
| action | 9 to 14 | 1 | No data: no coverage report in this map | No data: no coverage report in this map | No data: no mutants in this code |
| loader | 16 to 18 | 1 | No data: no coverage report in this map | No data: no coverage report in this map | No data: no mutants in this code |
Imports
It imports no other module of this repo. No module of this repo imports it.
Source
import { redirect } from "react-router";
/**
* Signing out of Access is its own endpoint on this host: it clears the Access cookie, which no code
* here can do. Nothing else holds a session, so this only sends the browser there.
*/
export const ACCESS_LOGOUT_PATH = "/cdn-cgi/access/logout";
export async function action() {
return new Response(null, {
status: 303,
headers: { Location: ACCESS_LOGOUT_PATH, "Cache-Control": "no-store" },
});
}
export async function loader() {
throw redirect("/admin");
}