1
0
Fork 0

Replace deprecated defaults() calls with ?? and ?: in include/ and view/

This commit is contained in:
Hypolite Petovan 2019-10-16 08:43:59 -04:00
commit 8b836189d4
11 changed files with 30 additions and 30 deletions

View file

@ -29,7 +29,7 @@ function vier_init(App $a)
Renderer::setActiveTemplateEngine('smarty3');
if (!empty($a->argv[0]) && $a->argv[0] . defaults($a->argv, 1, '') === "profile".$a->user['nickname'] || $a->argv[0] === "network" && local_user()) {
if (!empty($a->argv[0]) && ($a->argv[0] . ($a->argv[1] ?? '')) === ('profile' . $a->user['nickname']) || $a->argv[0] === 'network' && local_user()) {
vier_community_info();
$a->page['htmlhead'] .= "<link rel='stylesheet' type='text/css' href='view/theme/vier/wide.css' media='screen and (min-width: 1300px)'/>\n";
@ -191,7 +191,7 @@ function vier_community_info()
//Community_Pages at right_aside
if ($show_pages && local_user()) {
$cid = defaults($_GET, 'cid', null);
$cid = $_GET['cid'] ?? null;
//sort by last updated item
$lastitem = true;