"SELECT `intro`.`id`, `intro`.`datetime`,
`contact`.`name`, `contact`.`url`, `contact`.`photo`
FROM `intro` INNER JOIN `contact` ON `intro`.`contact-id` = `contact`.`id`
- WHERE `intro`.`uid` = %d AND NOT `intro`.`blocked` AND NOT `intro`.`ignore` AND `intro`.`contact-id` != 0 AND `intro`.`fid` = 0",
+ WHERE `intro`.`uid` = %d AND NOT `intro`.`blocked` AND NOT `intro`.`ignore` AND `intro`.`contact-id` != 0 AND (`intro`.`fid` = 0 OR `intro`.`fid` IS NULL)",
intval(local_user())
);
'seen' => false,
'message' => DI::l10n()->t('{0} requested registration'),
];
- $notifs[] = $notif;
+ $notifications[] = $notif;
}
} else {
$notif = [
array_walk($notifications, function (&$notification) {
if (empty($notification['photo'])) {
$contact = Contact::getByURL($notification['url'], false, ['micro', 'id', 'avatar']);
- $notification['photo'] = Contact::getMicro($contact, $notif['photo']);
+ $notification['photo'] = Contact::getMicro($contact, $notification['photo']);
}
$notification['timestamp'] = DateTimeFormat::local($notification['date']);
+ $notification['date'] = Temporal::getRelativeDate($notification['date']);
});
}