]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - lib/inboxnoticestream.php
Add Attention class for non-sub and non-mention notice attentions
[quix0rs-gnu-social.git] / lib / inboxnoticestream.php
index cb81042e2b1fafac8d00fa9099469f2e1c4987db..84cac7c67b97462f68e628bd5fda50b96ec24ade 100644 (file)
@@ -107,7 +107,9 @@ class RawInboxNoticeStream extends NoticeStream
         // Subscription:: is a table of subscriptions (every user is subscribed to themselves)
         $notice->whereAdd(
                 sprintf('notice.id IN (SELECT notice_id FROM reply WHERE profile_id=%1$d) ' .
-                    'OR notice.profile_id IN (SELECT subscribed FROM subscription WHERE subscriber=%d)', $this->target->id)
+                        'OR notice.profile_id IN (SELECT subscribed FROM subscription WHERE subscriber=%d) ' .
+                        'OR notice.id IN (SELECT notice_id FROM attention WHERE profile_id=%1$d)',
+                    $this->target->id)
             );
         $notice->limit($offset, $limit);
         $notice->orderBy('notice.created DESC');