mirror of
https://git.friendi.ca/friendica/friendica.git
synced 2025-06-17 02:05:19 +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
|
@ -57,9 +57,9 @@ function theme_post(App $a)
|
|||
}
|
||||
}
|
||||
|
||||
function theme_admin_post(App $a)
|
||||
function theme_admin_post()
|
||||
{
|
||||
if (!$a->isSiteAdmin()) {
|
||||
if (!DI::userSession()->isSiteAdmin()) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -199,7 +199,7 @@ function frio_remote_nav(array &$nav_info)
|
|||
{
|
||||
if (DI::mode()->has(App\Mode::MAINTENANCEDISABLED)) {
|
||||
// get the homelink from $_SESSION
|
||||
$homelink = Profile::getMyURL();
|
||||
$homelink = DI::userSession()->getMyUrl();
|
||||
if (!$homelink) {
|
||||
$homelink = DI::session()->get('visitor_home', '');
|
||||
}
|
||||
|
@ -212,7 +212,7 @@ function frio_remote_nav(array &$nav_info)
|
|||
} elseif (!DI::userSession()->getLocalUserId() && DI::userSession()->getRemoteUserId()) {
|
||||
$remoteUser = Contact::getById(DI::userSession()->getRemoteUserId(), $fields);
|
||||
$nav_info['nav']['remote'] = DI::l10n()->t('Guest');
|
||||
} elseif (Profile::getMyURL()) {
|
||||
} elseif (DI::userSession()->getMyUrl()) {
|
||||
$remoteUser = Contact::getByURL($homelink, null, $fields);
|
||||
$nav_info['nav']['remote'] = DI::l10n()->t('Visitor');
|
||||
} else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue