Remove fake private message notifications from ping output
This commit is contained in:
parent
36f995ed20
commit
e9b05bd13f
1 changed files with 1 additions and 17 deletions
18
mod/ping.php
18
mod/ping.php
|
@ -275,22 +275,6 @@ function ping_init(App $a)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (DBA::isResult($mails)) {
|
|
||||||
foreach ($mails as $mail) {
|
|
||||||
$notif = [
|
|
||||||
'id' => 0,
|
|
||||||
'href' => System::baseUrl() . '/message/' . $mail['id'],
|
|
||||||
'name' => $mail['from-name'],
|
|
||||||
'url' => $mail['from-url'],
|
|
||||||
'photo' => $mail['from-photo'],
|
|
||||||
'date' => $mail['created'],
|
|
||||||
'seen' => false,
|
|
||||||
'message' => L10n::t('{0} sent you a message'),
|
|
||||||
];
|
|
||||||
$notifs[] = $notif;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (DBA::isResult($regs)) {
|
if (DBA::isResult($regs)) {
|
||||||
foreach ($regs as $reg) {
|
foreach ($regs as $reg) {
|
||||||
$notif = [
|
$notif = [
|
||||||
|
@ -377,7 +361,7 @@ function ping_init(App $a)
|
||||||
if ($format == 'json') {
|
if ($format == 'json') {
|
||||||
$data['groups'] = $groups_unseen;
|
$data['groups'] = $groups_unseen;
|
||||||
$data['forums'] = $forums_unseen;
|
$data['forums'] = $forums_unseen;
|
||||||
$data['notify'] = $sysnotify_count + $intro_count + $mail_count + $register_count;
|
$data['notify'] = $sysnotify_count + $intro_count + $register_count;
|
||||||
$data['notifications'] = $notifications;
|
$data['notifications'] = $notifications;
|
||||||
$data['sysmsgs'] = [
|
$data['sysmsgs'] = [
|
||||||
'notice' => $sysmsgs,
|
'notice' => $sysmsgs,
|
||||||
|
|
Loading…
Reference in a new issue