This commit is contained in:
Freya Murphy 2024-05-27 00:40:13 -04:00
parent cb9d1193c3
commit 9182d5c887
Signed by: freya
GPG key ID: 744AB800E383AE52

View file

@ -53,11 +53,11 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST') {
$host = $_SERVER['HTTP_HOST'];
$env = getenv("HTTP_HOST");
if ($host != $env) {
if ($_SERVER['REQUEST_URI'] !== '/login') {
// we are being forwarded authed
// redirect
http_response_code(301);
header("Location: https://$env");
header("Location: https://$env/login");
} else {
page('login', array(
'title' => 'Login'