mirror of
https://github.com/friendica/friendica
synced 2025-04-29 05:04:24 +02:00
Some more deprecated function calls are replaced
This commit is contained in:
parent
bd6616e84f
commit
e12f92e516
30 changed files with 101 additions and 163 deletions
|
@ -87,7 +87,7 @@ class Renderer
|
|||
$output = $t->replaceMacros($template, $vars);
|
||||
} catch (Exception $e) {
|
||||
DI::logger()->critical($e->getMessage(), ['template' => $template, 'vars' => $vars]);
|
||||
$message = DI::app()->isSiteAdmin() ?
|
||||
$message = DI::userSession()->isSiteAdmin() ?
|
||||
$e->getMessage() :
|
||||
DI::l10n()->t('Friendica can\'t display this page at the moment, please contact the administrator.');
|
||||
throw new ServiceUnavailableException($message);
|
||||
|
@ -116,7 +116,7 @@ class Renderer
|
|||
$template = $t->getTemplateFile($file, $subDir);
|
||||
} catch (Exception $e) {
|
||||
DI::logger()->critical($e->getMessage(), ['file' => $file, 'subDir' => $subDir]);
|
||||
$message = DI::app()->isSiteAdmin() ?
|
||||
$message = DI::userSession()->isSiteAdmin() ?
|
||||
$e->getMessage() :
|
||||
DI::l10n()->t('Friendica can\'t display this page at the moment, please contact the administrator.');
|
||||
throw new ServiceUnavailableException($message);
|
||||
|
@ -145,7 +145,7 @@ class Renderer
|
|||
} else {
|
||||
$admin_message = DI::l10n()->t('template engine cannot be registered without a name.');
|
||||
DI::logger()->critical($admin_message, ['class' => $class]);
|
||||
$message = DI::app()->isSiteAdmin() ?
|
||||
$message = DI::userSession()->isSiteAdmin() ?
|
||||
$admin_message :
|
||||
DI::l10n()->t('Friendica can\'t display this page at the moment, please contact the administrator.');
|
||||
throw new ServiceUnavailableException($message);
|
||||
|
@ -179,7 +179,7 @@ class Renderer
|
|||
|
||||
$admin_message = DI::l10n()->t('template engine is not registered!');
|
||||
DI::logger()->critical($admin_message, ['template_engine' => $template_engine]);
|
||||
$message = DI::app()->isSiteAdmin() ?
|
||||
$message = DI::userSession()->isSiteAdmin() ?
|
||||
$admin_message :
|
||||
DI::l10n()->t('Friendica can\'t display this page at the moment, please contact the administrator.');
|
||||
throw new ServiceUnavailableException($message);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue