mirror of
https://github.com/pixelfed/pixelfed.git
synced 2024-12-28 02:36:50 +00:00
commit
4c0c29ee37
2 changed files with 6 additions and 2 deletions
|
@ -4,6 +4,7 @@
|
||||||
|
|
||||||
### Updates
|
### Updates
|
||||||
- Update Notifications.vue component, fix filtering logic to prevent endless spinner ([3df9b53f](https://github.com/pixelfed/pixelfed/commit/3df9b53f))
|
- Update Notifications.vue component, fix filtering logic to prevent endless spinner ([3df9b53f](https://github.com/pixelfed/pixelfed/commit/3df9b53f))
|
||||||
|
- Update Direct Messages, fix api endpoint ([fe8728c0](https://github.com/pixelfed/pixelfed/commit/fe8728c0))
|
||||||
- ([](https://github.com/pixelfed/pixelfed/commit/))
|
- ([](https://github.com/pixelfed/pixelfed/commit/))
|
||||||
|
|
||||||
## [v0.11.8 (2023-05-29)](https://github.com/pixelfed/pixelfed/compare/v0.11.7...v0.11.8)
|
## [v0.11.8 (2023-05-29)](https://github.com/pixelfed/pixelfed/compare/v0.11.7...v0.11.8)
|
||||||
|
|
|
@ -2447,14 +2447,17 @@ class ApiV1Controller extends Controller
|
||||||
'id' => $dm->id,
|
'id' => $dm->id,
|
||||||
'unread' => false,
|
'unread' => false,
|
||||||
'accounts' => [
|
'accounts' => [
|
||||||
AccountService::getMastodon($from)
|
AccountService::getMastodon($from, true)
|
||||||
],
|
],
|
||||||
'last_status' => StatusService::getDirectMessage($dm->status_id)
|
'last_status' => StatusService::getDirectMessage($dm->status_id)
|
||||||
];
|
];
|
||||||
return $res;
|
return $res;
|
||||||
})
|
})
|
||||||
->filter(function($dm) {
|
->filter(function($dm) {
|
||||||
return isset($dm['accounts']) && count($dm['accounts']) && !empty($dm['last_status']);
|
if(!$dm || empty($dm['last_status']) || !isset($dm['accounts']) || !count($dm['accounts']) || !isset($dm['accounts'][0]) || !isset($dm['accounts'][0]['id'])) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return true;
|
||||||
})
|
})
|
||||||
->unique(function($item, $key) {
|
->unique(function($item, $key) {
|
||||||
return $item['accounts'][0]['id'];
|
return $item['accounts'][0]['id'];
|
||||||
|
|
Loading…
Reference in a new issue