adadsa
All checks were successful
Deploy / deploy-staging (push) Successful in 24s
Deploy / deploy-production (push) Has been skipped

This commit is contained in:
2026-06-15 23:45:59 +02:00
parent 84a367bdc9
commit 29b5987aac
5 changed files with 25 additions and 11 deletions

View File

@@ -56,11 +56,12 @@ if ($state === '' || $expectedState === '' || !hash_equals($expectedState, $stat
$accountCheck = $accountGate->checkUsername($username);
if (!($accountCheck['allowed'] ?? false)) {
$auth->logout();
$target = (string) ($accountCheck['state'] ?? '') === 'pending'
? '/auth/pending/?username=' . urlencode($username)
: '/auth/inactive/?message=' . urlencode((string) ($accountCheck['message'] ?? 'Dieses Konto ist noch nicht freigeschaltet.'));
header('Location: ' . $target, true, 302);
$logoutUrl = $auth->logoutUrl($target, (string) ($tokenPayload['id_token'] ?? ''));
$auth->logout();
header('Location: ' . $logoutUrl, true, 302);
exit;
} else {
$auth->establishSession($tokenPayload, $userPayload);