diff options
author | Mario Vavti <mario@mariovavti.com> | 2022-10-20 11:15:06 +0200 |
---|---|---|
committer | Mario Vavti <mario@mariovavti.com> | 2022-10-20 11:15:06 +0200 |
commit | 53931017b99c6fc77fc7632747e51b06a89b2287 (patch) | |
tree | 26357decc1d3a76471863b3f58a0a0455d637e33 /include/nav.php | |
parent | e9ca17cec14c5a702cc7d656e5206a3c086dd550 (diff) | |
download | volse-hubzilla-53931017b99c6fc77fc7632747e51b06a89b2287.tar.gz volse-hubzilla-53931017b99c6fc77fc7632747e51b06a89b2287.tar.bz2 volse-hubzilla-53931017b99c6fc77fc7632747e51b06a89b2287.zip |
fix php warnings
Diffstat (limited to 'include/nav.php')
-rw-r--r-- | include/nav.php | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/include/nav.php b/include/nav.php index 71b3bec49..29d99aaee 100644 --- a/include/nav.php +++ b/include/nav.php @@ -110,12 +110,12 @@ function nav($template = 'default') { $nav['logout'] = ['logout', t('Logout'), "", t('End this session'), 'logout_nav_btn']; // user menu - $nav['usermenu'][] = ['profile/' . $channel['channel_address'], t('View Profile'), ((App::$nav_sel['raw_name'] == 'Profile') ? 'active' : ''), t('Your profile page'), 'profile_nav_btn']; + $nav['usermenu'][] = ['profile/' . $channel['channel_address'], t('View Profile'), ((isset(App::$nav_sel['raw_name']) && App::$nav_sel['raw_name'] == 'Profile') ? 'active' : ''), t('Your profile page'), 'profile_nav_btn']; if (feature_enabled(local_channel(), 'multi_profiles')) - $nav['usermenu'][] = ['profiles', t('Edit Profiles'), ((App::$nav_sel['raw_name'] == 'Profiles') ? 'active' : ''), t('Manage/Edit profiles'), 'profiles_nav_btn']; + $nav['usermenu'][] = ['profiles', t('Edit Profiles'), ((isset(App::$nav_sel['raw_name']) && App::$nav_sel['raw_name'] == 'Profiles') ? 'active' : ''), t('Manage/Edit profiles'), 'profiles_nav_btn']; else - $nav['usermenu'][] = ['profiles/' . $prof[0]['id'], t('Edit Profile'), ((App::$nav_sel['raw_name'] == 'Profiles') ? 'active' : ''), t('Edit your profile'), 'profiles_nav_btn']; + $nav['usermenu'][] = ['profiles/' . $prof[0]['id'], t('Edit Profile'), ((isset(App::$nav_sel['raw_name']) && App::$nav_sel['raw_name'] == 'Profiles') ? 'active' : ''), t('Edit your profile'), 'profiles_nav_btn']; } else { @@ -276,7 +276,7 @@ function nav($template = 'default') { if ($pinned_list) { foreach ($pinned_list as $app) { - if (App::$nav_sel['name'] == $app['name']) + if (isset(App::$nav_sel['name']) && App::$nav_sel['name'] == $app['name']) $app['active'] = true; if ($is_owner) { |