mirror of
https://git.sekbaer.de/Friendica/friendica.git
synced 2025-06-07 15:54:26 +02:00
Fix code style
This commit is contained in:
parent
d4697a17a3
commit
0e59dba914
102 changed files with 3038 additions and 2764 deletions
|
@ -29,7 +29,7 @@ const FRIO_SCHEME_ACCENT_GREEN = '#218f39';
|
|||
const FRIO_SCHEME_ACCENT_PINK = '#d900a9';
|
||||
|
||||
const FRIO_DEFAULT_SCHEME = 'light';
|
||||
const FRIO_CUSTOM_SCHEME = '---';
|
||||
const FRIO_CUSTOM_SCHEME = '---';
|
||||
|
||||
/*
|
||||
* This script can be included even when the app is in maintenance mode which requires us to avoid any config call
|
||||
|
@ -80,9 +80,9 @@ function frio_install()
|
|||
function frio_item_photo_links(&$body_info)
|
||||
{
|
||||
$occurence = 0;
|
||||
$p = Plaintext::getBoundariesPosition($body_info['html'], '<a', '>');
|
||||
$p = Plaintext::getBoundariesPosition($body_info['html'], '<a', '>');
|
||||
while ($p !== false && ($occurence++ < 500)) {
|
||||
$link = substr($body_info['html'], $p['start'], $p['end'] - $p['start']);
|
||||
$link = substr($body_info['html'], $p['start'], $p['end'] - $p['start']);
|
||||
$matches = [];
|
||||
|
||||
preg_match('/\/photos\/[\w]+\/image\/([\w]+)/', $link, $matches);
|
||||
|
@ -116,7 +116,7 @@ function frio_item_photo_menu(&$arr)
|
|||
{
|
||||
foreach ($arr['menu'] as $k => $v) {
|
||||
if (strpos($v, 'message/new/') === 0) {
|
||||
$v = 'javascript:addToModal(\'' . $v . '\'); return false;';
|
||||
$v = 'javascript:addToModal(\'' . $v . '\'); return false;';
|
||||
$arr['menu'][$k] = $v;
|
||||
}
|
||||
}
|
||||
|
@ -154,7 +154,7 @@ function frio_contact_photo_menu(&$args)
|
|||
// and if it's a friendica contact we set it to false
|
||||
foreach ($args['menu'] as $k => $v) {
|
||||
if ($k === 'status' || $k === 'profile' || $k === 'photos') {
|
||||
$v[2] = (($args['contact']['network'] === 'dfrn') ? false : true);
|
||||
$v[2] = (($args['contact']['network'] === 'dfrn') ? false : true);
|
||||
$args['menu'][$k][2] = $v[2];
|
||||
}
|
||||
}
|
||||
|
@ -210,7 +210,7 @@ function frio_remote_nav(array &$nav_info)
|
|||
'icon' => Contact::getMicro($remoteUser),
|
||||
'name' => $remoteUser['name'],
|
||||
];
|
||||
$server_url = $remoteUser['baseurl'];
|
||||
$server_url = $remoteUser['baseurl'];
|
||||
}
|
||||
|
||||
if (!DI::userSession()->getLocalUserId() && !empty($server_url) && !is_null($remoteUser)) {
|
||||
|
|
|
@ -50,8 +50,11 @@ header('Last-Modified: '.$modified);
|
|||
|
||||
if (isset($_SERVER['HTTP_IF_MODIFIED_SINCE']) && isset($_SERVER['HTTP_IF_NONE_MATCH'])) {
|
||||
$cached_modified = gmdate('r', strtotime($_SERVER['HTTP_IF_MODIFIED_SINCE']));
|
||||
$cached_etag = str_replace(['"', "-gzip"], ['', ''],
|
||||
stripslashes($_SERVER['HTTP_IF_NONE_MATCH']));
|
||||
$cached_etag = str_replace(
|
||||
['"', "-gzip"],
|
||||
['', ''],
|
||||
stripslashes($_SERVER['HTTP_IF_NONE_MATCH'])
|
||||
);
|
||||
|
||||
if (($cached_modified == $modified) && ($cached_etag == $etag)) {
|
||||
throw new NotModifiedException();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue