#8889 Fixed url location

This commit is contained in:
Daniel Maya 2022-07-14 16:50:26 +02:00
parent 66a69aa548
commit 0ff688f6fa

View File

@ -193,15 +193,23 @@ switch ($action) {
if ($user->isWaitingDoubleAuth()) { if ($user->isWaitingDoubleAuth()) {
if ($user->validateDoubleAuthCode()) { if ($user->validateDoubleAuthCode()) {
// Logged. Refresh the page $url = ui_get_full_url('');
header('Location: .'); $url = str_replace("\n", '', $url);
$url = str_replace('?action=logout', '', $url);
// Logged. Refresh the page.
header('Location: '.$url);
return; return;
} else { } else {
$user->showDoubleAuthPage(); $user->showDoubleAuthPage();
} }
} else { } else {
// Logged. Refresh the page $url = ui_get_full_url('');
header('Location: .'); $url = str_replace("\n", '', $url);
$url = str_replace('?action=logout', '', $url);
// Logged. Refresh the page.
header('Location: '.$url);
return; return;
} }
} else { } else {