mirror of
https://github.com/friendica/friendica
synced 2025-04-29 13:04:23 +02:00
Escape global namespaced get_app() calls
- Add deprecated status
This commit is contained in:
parent
b8030313e5
commit
5e1ceb57de
52 changed files with 135 additions and 133 deletions
|
@ -909,7 +909,7 @@ class Contact extends BaseObject
|
|||
public static function photoMenu(array $contact, $uid = 0)
|
||||
{
|
||||
// @todo Unused, to be removed
|
||||
$a = get_app();
|
||||
$a = \get_app();
|
||||
|
||||
$contact_url = '';
|
||||
$pm_url = '';
|
||||
|
@ -1631,7 +1631,7 @@ class Contact extends BaseObject
|
|||
{
|
||||
$result = ['cid' => -1, 'success' => false, 'message' => ''];
|
||||
|
||||
$a = get_app();
|
||||
$a = \get_app();
|
||||
|
||||
// remove ajax junk, e.g. Twitter
|
||||
$url = str_replace('/#!/', '/', $url);
|
||||
|
|
|
@ -518,7 +518,7 @@ class GContact
|
|||
*/
|
||||
public static function updateSuggestions()
|
||||
{
|
||||
$a = get_app();
|
||||
$a = \get_app();
|
||||
|
||||
$done = [];
|
||||
|
||||
|
|
|
@ -1148,7 +1148,7 @@ class Item extends BaseObject
|
|||
if ($notify) {
|
||||
// We have to avoid duplicates. So we create the GUID in form of a hash of the plink or uri.
|
||||
// We add the hash of our own host because our host is the original creator of the post.
|
||||
$prefix_host = get_app()->getHostName();
|
||||
$prefix_host = \get_app()->getHostName();
|
||||
} else {
|
||||
$prefix_host = '';
|
||||
|
||||
|
@ -1238,7 +1238,7 @@ class Item extends BaseObject
|
|||
|
||||
public static function insert($item, $force_parent = false, $notify = false, $dontcache = false)
|
||||
{
|
||||
$a = get_app();
|
||||
$a = \get_app();
|
||||
|
||||
// If it is a posting where users should get notifications, then define it as wall posting
|
||||
if ($notify) {
|
||||
|
@ -2611,7 +2611,7 @@ class Item extends BaseObject
|
|||
|
||||
public static function isRemoteSelf($contact, &$datarray)
|
||||
{
|
||||
$a = get_app();
|
||||
$a = \get_app();
|
||||
|
||||
if (!$contact['remote_self']) {
|
||||
return false;
|
||||
|
|
|
@ -28,7 +28,7 @@ class Mail
|
|||
*/
|
||||
public static function send($recipient = 0, $body = '', $subject = '', $replyto = '')
|
||||
{
|
||||
$a = get_app();
|
||||
$a = \get_app();
|
||||
|
||||
if (!$recipient) {
|
||||
return -1;
|
||||
|
|
|
@ -144,7 +144,7 @@ class Photo
|
|||
$micro = System::baseUrl() . '/photo/' . $hash . '-6.' . $Image->getExt() . $suffix;
|
||||
|
||||
// Remove the cached photo
|
||||
$a = get_app();
|
||||
$a = \get_app();
|
||||
$basepath = $a->getBasePath();
|
||||
|
||||
if (is_dir($basepath . "/photo")) {
|
||||
|
|
|
@ -280,7 +280,7 @@ class Profile
|
|||
*/
|
||||
private static function sidebar($profile, $block = 0, $show_connect = true)
|
||||
{
|
||||
$a = get_app();
|
||||
$a = \get_app();
|
||||
|
||||
$o = '';
|
||||
$location = false;
|
||||
|
@ -551,7 +551,7 @@ class Profile
|
|||
|
||||
public static function getBirthdays()
|
||||
{
|
||||
$a = get_app();
|
||||
$a = \get_app();
|
||||
$o = '';
|
||||
|
||||
if (!local_user() || $a->is_mobile || $a->is_tablet) {
|
||||
|
@ -649,7 +649,7 @@ class Profile
|
|||
|
||||
public static function getEventsReminderHTML()
|
||||
{
|
||||
$a = get_app();
|
||||
$a = \get_app();
|
||||
$o = '';
|
||||
|
||||
if (!local_user() || $a->is_mobile || $a->is_tablet) {
|
||||
|
@ -1090,7 +1090,7 @@ class Profile
|
|||
*/
|
||||
public static function openWebAuthInit($token)
|
||||
{
|
||||
$a = get_app();
|
||||
$a = \get_app();
|
||||
|
||||
// Clean old OpenWebAuthToken entries.
|
||||
OpenWebAuthToken::purge('owt', '3 MINUTE');
|
||||
|
|
|
@ -406,7 +406,7 @@ class User
|
|||
*/
|
||||
public static function create(array $data)
|
||||
{
|
||||
$a = get_app();
|
||||
$a = \get_app();
|
||||
$return = ['user' => null, 'password' => ''];
|
||||
|
||||
$using_invites = Config::get('system', 'invitation_only');
|
||||
|
@ -795,7 +795,7 @@ class User
|
|||
return false;
|
||||
}
|
||||
|
||||
$a = get_app();
|
||||
$a = \get_app();
|
||||
|
||||
Logger::log('Removing user: ' . $uid);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue