Move L10n::t() calls to DI::l10n()->t() calls

This commit is contained in:
nupplaPhil 2020-01-18 20:52:34 +01:00
parent af88c2daa3
commit 5dfee31108
No known key found for this signature in database
GPG key ID: D8365C3D36B77D90
175 changed files with 2841 additions and 2841 deletions

View file

@ -33,7 +33,7 @@ class AllFriends extends BaseModule
}
if (!$cid) {
throw new HTTPException\BadRequestException(L10n::t('Invalid contact.'));
throw new HTTPException\BadRequestException(DI::l10n()->t('Invalid contact.'));
}
$uid = $app->user['uid'];
@ -41,7 +41,7 @@ class AllFriends extends BaseModule
$contact = Model\Contact::getContactForUser($cid, local_user(), ['name', 'url', 'photo', 'uid', 'id']);
if (empty($contact)) {
throw new HTTPException\BadRequestException(L10n::t('Invalid contact.'));
throw new HTTPException\BadRequestException(DI::l10n()->t('Invalid contact.'));
}
DI::page()['aside'] = "";
@ -53,7 +53,7 @@ class AllFriends extends BaseModule
$friends = Model\GContact::allFriends(local_user(), $cid, $pager->getStart(), $pager->getItemsPerPage());
if (empty($friends)) {
return L10n::t('No friends to display.');
return DI::l10n()->t('No friends to display.');
}
$id = 0;
@ -72,8 +72,8 @@ class AllFriends extends BaseModule
} else {
$connlnk = DI::baseUrl()->get() . '/follow/?url=' . $friend['url'];
$photoMenu = [
'profile' => [L10n::t('View Profile'), Model\Contact::magicLinkbyId($friend['id'], $friend['url'])],
'follow' => [L10n::t('Connect/Follow'), $connlnk]
'profile' => [DI::l10n()->t('View Profile'), Model\Contact::magicLinkbyId($friend['id'], $friend['url'])],
'follow' => [DI::l10n()->t('Connect/Follow'), $connlnk]
];
}
@ -89,7 +89,7 @@ class AllFriends extends BaseModule
'account_type' => Model\Contact::getAccountType($contactDetails),
'network' => ContactSelector::networkToName($contactDetails['network'], $contactDetails['url']),
'photoMenu' => $photoMenu,
'conntxt' => L10n::t('Connect'),
'conntxt' => DI::l10n()->t('Connect'),
'connlnk' => $connlnk,
'id' => ++$id,
];