Merge pull request #9724 from MrPetovan/bug/notices

Various improvements
This commit is contained in:
Michael Vogel 2020-12-31 17:30:50 +01:00 committed by GitHub
commit 54db693e16
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 18 additions and 20 deletions

View file

@ -69,9 +69,15 @@ class HTTPException
$message = $explanation[$e->getCode()] ?? '';
}
$vars = ['$title' => $title, '$message' => $message, '$back' => DI::l10n()->t('Go back')];
$vars = [
'$title' => $title,
'$message' => $message,
'$back' => DI::l10n()->t('Go back'),
'$stack_trace' => DI::l10n()->t('Stack trace:'),
];
if (is_site_admin()) {
$vars['$thrown'] = DI::l10n()->t('Exception thrown in %s:%d', $e->getFile(), $e->getLine());
$vars['$trace'] = $e->getTraceAsString();
}

View file

@ -84,7 +84,7 @@ final class ACLFormatter
private function sanitizeItem(string &$item) {
// The item is an ACL int value
if (intval($item)) {
$item = '<' . intval(Strings::escapeTags(trim($item))) . '>';
$item = '<' . intval($item) . '>';
// The item is a allowed ACL character
} elseif (in_array($item, [Group::FOLLOWERS, Group::MUTUALS])) {
$item = '<' . $item . '>';