Skip to content
Snippets Groups Projects
Commit 11f8c721 authored by Pavel Břoušek's avatar Pavel Břoušek
Browse files

chore: merge branch 'fix_ban' into 'main'

fix: use userId in ban filter

See merge request perun-proxy-aai/simplesamlphp/simplesamlphp-module-perun!312
parents 9b8e8256 a1ca6652
No related branches found
No related tags found
1 merge request!312fix: use userId in ban filter
Pipeline #292241 passed with warnings
......@@ -75,11 +75,12 @@ class IsBanned extends ProcessingFilter
);
}
if ($this->banExists($user)) {
Logger::info('perun:IsBanned: user ' . $user . ' is banned, redirecting to configured URL');
$userId = $user->getId();
if ($this->banExists($userId)) {
Logger::info('perun:IsBanned: user ' . $userId . ' is banned, redirecting to configured URL');
HTTP::redirectTrustedURL($this->redirectUrl);
} else {
Logger::debug('perun:IsBanned: user ' . $user . ' is not banned');
Logger::debug('perun:IsBanned: user ' . $userId . ' is not banned');
}
}
......
function getTranslation(str) {
return JSON.parse(
document.getElementById("translations").getAttribute("content")
document.getElementById("translations").getAttribute("content"),
)[str];
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment