// Transform the different types of notification in an usable array
switch ($notification['verb']) {
case Activity::LIKE:
- $formattedNotify = [
+ $formattedNotification = [
'label' => 'like',
'link' => $this->baseUrl->get(true) . '/display/' . $notification['parent-guid'],
'image' => ProxyUtils::proxifyUrl($notification['author-avatar'], false, ProxyUtils::SIZE_MICRO),
break;
case Activity::DISLIKE:
- $formattedNotify = [
+ $formattedNotification = [
'label' => 'dislike',
'link' => $this->baseUrl->get(true) . '/display/' . $notification['parent-guid'],
'image' => ProxyUtils::proxifyUrl($notification['author-avatar'], false, ProxyUtils::SIZE_MICRO),
break;
case Activity::ATTEND:
- $formattedNotify = [
+ $formattedNotification = [
'label' => 'attend',
'link' => $this->baseUrl->get(true) . '/display/' . $notification['parent-guid'],
'image' => ProxyUtils::proxifyUrl($notification['author-avatar'], false, ProxyUtils::SIZE_MICRO),
break;
case Activity::ATTENDNO:
- $formattedNotify = [
+ $formattedNotification = [
'label' => 'attendno',
'link' => $this->baseUrl->get(true) . '/display/' . $notification['parent-guid'],
'image' => ProxyUtils::proxifyUrl($notification['author-avatar'], false, ProxyUtils::SIZE_MICRO),
break;
case Activity::ATTENDMAYBE:
- $formattedNotify = [
+ $formattedNotification = [
'label' => 'attendmaybe',
'link' => $this->baseUrl->get(true) . '/display/' . $notification['parent-guid'],
'image' => ProxyUtils::proxifyUrl($notification['author-avatar'], false, ProxyUtils::SIZE_MICRO),
case Activity::FRIEND:
if (!isset($notification['object'])) {
- $formattedNotify = [
+ $formattedNotification = [
'label' => 'friend',
'link' => $default_item_link,
'image' => $default_item_image,
$obj = XML::parseString($xmlHead . $notification['object']);
$notification['fname'] = $obj->title;
- $formattedNotify = [
+ $formattedNotification = [
'label' => 'friend',
'link' => $this->baseUrl->get(true) . '/display/' . $notification['parent-guid'],
'image' => ProxyUtils::proxifyUrl($notification['author-avatar'], false, ProxyUtils::SIZE_MICRO),
break;
default:
- $formattedNotify = [
+ $formattedNotification = [
'label' => $default_item_label,
'link' => $default_item_link,
'image' => $default_item_image,
];
}
- $formattedNotifications[] = $formattedNotify;
+ $formattedNotifications[] = $formattedNotification;
}
return $formattedNotifications;
*/
public function getNetworkList(bool $seen = false, int $start = 0, int $limit = self::DEFAULT_PAGE_LIMIT)
{
- $ident = self::NETWORK;
+ $ident = self::NETWORK;
$notifications = [];
$condition = ['wall' => false, 'uid' => local_user()];
*/
public function getSystemList(bool $seen = false, int $start = 0, int $limit = self::DEFAULT_PAGE_LIMIT)
{
- $ident = self::SYSTEM;
+ $ident = self::SYSTEM;
$notifications = [];
$filter = ['uid' => local_user()];
*/
public function getPersonalList(bool $seen = false, int $start = 0, int $limit = self::DEFAULT_PAGE_LIMIT)
{
- $ident = self::PERSONAL;
+ $ident = self::PERSONAL;
$notifications = [];
$myurl = str_replace('http://', '', DI::app()->contact['nurl']);
*/
public function getHomeList(bool $seen = false, int $start = 0, int $limit = self::DEFAULT_PAGE_LIMIT)
{
- $ident = self::HOME;
+ $ident = self::HOME;
$notifications = [];
$condition = ['wall' => true, 'uid' => local_user()];
public function getIntroList(bool $all = false, int $start = 0, int $limit = self::DEFAULT_PAGE_LIMIT, int $id = 0)
{
/// @todo sanitize wording according to SELF::INTRO
- $ident = 'introductions';
- $notifications = [];
- $sql_extra = "";
+ $ident = 'introductions';
+ $notifications = [];
+ $sql_extra = "";
if (empty($id)) {
if (!$all) {
$intro = [
'label' => 'friend_suggestion',
- 'notify_type' => $this->l10n->t('Friend Suggestion'),
+ 'str_type' => $this->l10n->t('Friend Suggestion'),
'intro_id' => $intro['intro_id'],
'madeby' => $intro['name'],
'madeby_url' => $intro['url'],
}
$intro = [
'label' => (($intro['network'] !== Protocol::OSTATUS) ? 'friend_request' : 'follower'),
- 'notify_type' => (($intro['network'] !== Protocol::OSTATUS) ? $this->l10n->t('Friend/Connect Request') : $this->l10n->t('New Follower')),
+ 'str_type' => (($intro['network'] !== Protocol::OSTATUS) ? $this->l10n->t('Friend/Connect Request') : $this->l10n->t('New Follower')),
'dfrn_id' => $intro['issued-id'],
'uid' => $_SESSION['uid'],
'intro_id' => $intro['intro_id'],