1
0
Fork 0

Merge pull request #3591 from pixelfed/staging

Staging
This commit is contained in:
daniel 2022-07-25 23:36:50 -06:00 committed by GitHub
commit 73da9030d7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 0 deletions

View File

@ -44,6 +44,7 @@
- Update ResetPasswordController redirectTo path to /i/web as /home is deprecated ([8803c6de](https://github.com/pixelfed/pixelfed/commit/8803c6de))
- Fix v1 api block/mute endpoints, refresh RelationshipService cache after relationship changes ([54a5c3be](https://github.com/pixelfed/pixelfed/commit/54a5c3be))
- Fix NotificationService bug returning html response on /api/v1/notifications endpoint when a notification id belonging to a deleted account is rendered by checking AccountService before NotificationTransformer. ([734b30e5](https://github.com/pixelfed/pixelfed/commit/734b30e5))
- Hydrate `favourited` and `reblogged` state on v1 context endpoint ([abb4f7e1](https://github.com/pixelfed/pixelfed/commit/abb4f7e1))
- ([](https://github.com/pixelfed/pixelfed/commit/))
## [v0.11.3 (2022-05-09)](https://github.com/pixelfed/pixelfed/compare/v0.11.2...v0.11.3)

View File

@ -2208,6 +2208,7 @@ class ApiV1Controller extends Controller
abort_if(!$request->user(), 403);
$user = $request->user();
$pid = $user->profile_id;
$status = StatusService::getMastodon($id, false);
if(!$status || !isset($status['account'])) {
@ -2244,6 +2245,11 @@ class ApiV1Controller extends Controller
->filter(function($post) {
return $post && isset($post['account']);
})
->map(function($status) use($pid) {
$status['favourited'] = LikeService::liked($pid, $status['id']);
$status['reblogged'] = ReblogService::get($pid, $status['id']);
return $status;
})
->values();
}