mirror of
https://git.sekbaer.de/Friendica/friendica.git
synced 2025-06-16 20:05:14 +02:00
Merge pull request #2351 from annando/1602-performance-unread-group
Optimized query for unread group postings
This commit is contained in:
commit
d0b5c16a20
2 changed files with 21 additions and 20 deletions
18
mod/ping.php
18
mod/ping.php
|
@ -219,19 +219,21 @@ function ping_init(&$a) {
|
|||
<home>$home</home>\r\n";
|
||||
if ($register!=0) echo "<register>$register</register>";
|
||||
|
||||
if ( count($groups_unseen) ) {
|
||||
if (count($groups_unseen)) {
|
||||
echo '<groups>';
|
||||
foreach ($groups_unseen as $it) {
|
||||
echo '<group id="' . $it['id'] . '">' . $it['count'] . "</group>";
|
||||
}
|
||||
foreach ($groups_unseen as $it)
|
||||
if ($it['count'] > 0)
|
||||
echo '<group id="'.$it['id'].'">'.$it['count']."</group>";
|
||||
|
||||
echo "</groups>";
|
||||
}
|
||||
|
||||
if ( count($forums_unseen) ) {
|
||||
if (count($forums_unseen)) {
|
||||
echo '<forums>';
|
||||
foreach ($forums_unseen as $it) {
|
||||
echo '<forum id="' . $it['id'] . '">' . $it['count'] . "</forum>";
|
||||
}
|
||||
foreach ($forums_unseen as $it)
|
||||
if ($it['count'] > 0)
|
||||
echo '<forum id="'.$it['id'].'">'.$it['count']."</forum>";
|
||||
|
||||
echo "</forums>";
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue