X-Git-Url: https://reisub.nsupdate.info/git/?a=blobdiff_plain;f=mod%2Fnotifications.php;h=091323d998c725b136ad038abe5f185b6cbaba2c;hb=59d06b6c7809179339f3e8bf82467a85f17294b8;hp=bc581b6dd34ef24cda3791cb2ae9bc8f36e3914c;hpb=3ea9b0680a0c8ff218ee42046405e6bc80c57719;p=friendica.git%2F.git diff --git a/mod/notifications.php b/mod/notifications.php index bc581b6dd3..091323d998 100644 --- a/mod/notifications.php +++ b/mod/notifications.php @@ -87,10 +87,11 @@ function notifications_content(App $a) $perpage = 20; $startrec = ($page * $perpage) - $perpage; + $notif_header = L10n::t('Notifications'); + // Get introductions if ((($a->argc > 1) && ($a->argv[1] == 'intros')) || (($a->argc == 1))) { Nav::setSelected('introductions'); - $notif_header = L10n::t('Notifications'); $all = (($a->argc > 2) && ($a->argv[2] == 'all')); @@ -132,12 +133,8 @@ function notifications_content(App $a) $notif_tpl = get_markup_template('notifications.tpl'); - if (!isset($notifs['ident'])) { - logger('Missing data in notifs: ' . json_encode($a->argv), LOGGER_DEBUG); - } - // Process the data for template creation - if ($notifs['ident'] === 'introductions') { + if (defaults($notifs, 'ident', '') === 'introductions') { $sugg = get_markup_template('suggestions.tpl'); $tpl = get_markup_template("intros.tpl"); @@ -280,7 +277,7 @@ function notifications_content(App $a) } // Normal notifications (no introductions) - } else { + } elseif (!empty($notifs['notifications'])) { // The template files we need in different cases for formatting the content $tpl_item_like = 'notifications_likes_item.tpl'; $tpl_item_dislike = 'notifications_dislikes_item.tpl';