mirror of
https://github.com/friendica/friendica
synced 2025-05-05 21:44:11 +02:00
Rename App Methods
- renamed a lot of App methods to CamelCase - replaced direct public variables with get-/set-Methods
This commit is contained in:
parent
5f9dd11cfb
commit
5a02e39a65
94 changed files with 481 additions and 338 deletions
|
@ -115,7 +115,7 @@ class Cron
|
|||
|
||||
// Ensure to have a .htaccess file.
|
||||
// this is a precaution for systems that update automatically
|
||||
$basepath = $a->get_basepath();
|
||||
$basepath = $a->getBasePath();
|
||||
if (!file_exists($basepath . '/.htaccess')) {
|
||||
copy($basepath . '/.htaccess-dist', $basepath . '/.htaccess');
|
||||
}
|
||||
|
|
|
@ -157,14 +157,14 @@ class CronJobs
|
|||
clear_cache();
|
||||
|
||||
// clear cache for photos
|
||||
clear_cache($a->get_basepath(), $a->get_basepath() . "/photo");
|
||||
clear_cache($a->getBasePath(), $a->getBasePath() . "/photo");
|
||||
|
||||
// clear smarty cache
|
||||
clear_cache($a->get_basepath() . "/view/smarty3/compiled", $a->get_basepath() . "/view/smarty3/compiled");
|
||||
clear_cache($a->getBasePath() . "/view/smarty3/compiled", $a->getBasePath() . "/view/smarty3/compiled");
|
||||
|
||||
// clear cache for image proxy
|
||||
if (!Config::get("system", "proxy_disabled")) {
|
||||
clear_cache($a->get_basepath(), $a->get_basepath() . "/proxy");
|
||||
clear_cache($a->getBasePath(), $a->getBasePath() . "/proxy");
|
||||
|
||||
$cachetime = Config::get('system', 'proxy_cache_time');
|
||||
|
||||
|
|
|
@ -112,7 +112,7 @@ class Delivery extends BaseObject
|
|||
// if $parent['wall'] == 1 we will already have the parent message in our array
|
||||
// and we will relay the whole lot.
|
||||
|
||||
$localhost = self::getApp()->get_hostname();
|
||||
$localhost = self::getApp()->getHostName();
|
||||
if (strpos($localhost, ':')) {
|
||||
$localhost = substr($localhost, 0, strpos($localhost, ':'));
|
||||
}
|
||||
|
@ -435,7 +435,7 @@ class Delivery extends BaseObject
|
|||
$headers = 'From: ' . Email::encodeHeader($local_user['username'],'UTF-8').' <' . $local_user['email'] . '>' . "\n";
|
||||
}
|
||||
} else {
|
||||
$headers = 'From: '. Email::encodeHeader($local_user['username'], 'UTF-8') . ' <noreply@' . self::getApp()->get_hostname() . '>' . "\n";
|
||||
$headers = 'From: '. Email::encodeHeader($local_user['username'], 'UTF-8') . ' <noreply@' . self::getApp()->getHostName() . '>' . "\n";
|
||||
}
|
||||
|
||||
$headers .= 'Message-Id: <' . Email::iri2msgid($target_item['uri']) . '>' . "\n";
|
||||
|
|
|
@ -194,7 +194,7 @@ class Notifier
|
|||
// if $parent['wall'] == 1 we will already have the parent message in our array
|
||||
// and we will relay the whole lot.
|
||||
|
||||
$localhost = str_replace('www.','',$a->get_hostname());
|
||||
$localhost = str_replace('www.','',$a->getHostName());
|
||||
if (strpos($localhost,':')) {
|
||||
$localhost = substr($localhost,0,strpos($localhost,':'));
|
||||
}
|
||||
|
|
|
@ -196,7 +196,7 @@ class OnePoll
|
|||
|
||||
$handshake_xml = $ret['body'];
|
||||
|
||||
$html_code = $a->get_curl_code();
|
||||
$html_code = Network::getCurl()->getCode();
|
||||
|
||||
logger('handshake with url ' . $url . ' returns xml: ' . $handshake_xml, LOGGER_DATA);
|
||||
|
||||
|
@ -507,7 +507,7 @@ class OnePoll
|
|||
}
|
||||
}
|
||||
|
||||
$fromarr = imap_rfc822_parse_adrlist($fromdecoded, $a->get_hostname());
|
||||
$fromarr = imap_rfc822_parse_adrlist($fromdecoded, $a->getHostName());
|
||||
|
||||
$frommail = $fromarr[0]->mailbox."@".$fromarr[0]->host;
|
||||
|
||||
|
|
|
@ -57,7 +57,7 @@ class PubSubPublish
|
|||
logger('POST ' . print_r($headers, true) . "\n" . $params, LOGGER_DATA);
|
||||
|
||||
Network::post($subscriber['callback_url'], $params, $headers);
|
||||
$ret = $a->get_curl_code();
|
||||
$ret = Network::getCurl()->getCode();
|
||||
|
||||
$condition = ['id' => $subscriber['id']];
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue