diff options
author | Maxence Lange <maxence@artificial-owl.com> | 2019-07-20 18:21:26 -0100 |
---|---|---|
committer | Maxence Lange <maxence@artificial-owl.com> | 2019-07-20 18:21:26 -0100 |
commit | 92ba1df1131c569e6dd772c9c44623f301ed3a84 (patch) | |
tree | aa4bf442a8e2fa847e3d7511e3dd5a989e1b3220 /lib | |
parent | febb64c897468139551599a80dbe06db42097e6d (diff) |
returns stream actions on liked timeline
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Db/StreamRequest.php | 3 | ||||
-rw-r--r-- | lib/Service/NoteService.php | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/lib/Db/StreamRequest.php b/lib/Db/StreamRequest.php index 365d83f5..db2dee29 100644 --- a/lib/Db/StreamRequest.php +++ b/lib/Db/StreamRequest.php @@ -518,12 +518,13 @@ class StreamRequest extends StreamRequestBuilder { * @return array * @throws Exception */ - public function getLiked(int $since = 0, int $limit = 5, bool $localOnly = true): array { + public function getTimelineLiked(int $since = 0, int $limit = 5, bool $localOnly = true): array { $qb = $this->getStreamSelectSql(); $this->limitPaginate($qb, $since, $limit); $this->limitToType($qb, Note::TYPE); + $this->leftJoinStreamAction($qb); $this->leftJoinCacheActors($qb, 'attributed_to'); $this->leftJoinActions($qb, Like::TYPE); $this->filterDBField($qb, 'id', '', false, 'a'); diff --git a/lib/Service/NoteService.php b/lib/Service/NoteService.php index b9043175..f13ffee8 100644 --- a/lib/Service/NoteService.php +++ b/lib/Service/NoteService.php @@ -464,7 +464,7 @@ class NoteService { * @throws Exception */ public function getStreamLiked(int $since = 0, int $limit = 5): array { - return $this->streamRequest->getLiked($since, $limit); + return $this->streamRequest->getTimelineLiked($since, $limit); } |