diff options
author | Christoph Wurst <christoph@winzerhof-wurst.at> | 2023-11-03 12:56:51 +0100 |
---|---|---|
committer | Christoph Wurst <christoph@winzerhof-wurst.at> | 2023-11-08 21:53:35 +0100 |
commit | 71080a8d20d5e7ee9e77768cdfa47ec07a200393 (patch) | |
tree | 20aef2824e7da16d0978c1ecf534129638817619 /apps/user_status/lib | |
parent | 1acc7c04684a05f024f4c83a8665d4732c2fc5f6 (diff) | |
download | nextcloud-server-71080a8d20d5e7ee9e77768cdfa47ec07a200393.tar.gz nextcloud-server-71080a8d20d5e7ee9e77768cdfa47ec07a200393.zip |
feat(contactsmenu): Sort by user status
If user_status is not enabled, fall back to sorting by contact name.
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
Diffstat (limited to 'apps/user_status/lib')
-rw-r--r-- | apps/user_status/lib/ContactsMenu/StatusProvider.php | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/apps/user_status/lib/ContactsMenu/StatusProvider.php b/apps/user_status/lib/ContactsMenu/StatusProvider.php index 3c37d6b080f..f1316f02df8 100644 --- a/apps/user_status/lib/ContactsMenu/StatusProvider.php +++ b/apps/user_status/lib/ContactsMenu/StatusProvider.php @@ -44,6 +44,7 @@ class StatusProvider implements IBulkProvider { ); $statuses = $this->statusService->findByUserIds($uids); + /** @var array<string, UserStatus> $indexed */ $indexed = array_combine( array_map(fn(UserStatus $status) => $status->getUserId(), $statuses), $statuses @@ -56,6 +57,7 @@ class StatusProvider implements IBulkProvider { $entry->setStatus( $status->getStatus(), $status->getCustomMessage(), + $status->getStatusMessageTimestamp(), $status->getCustomIcon(), ); } |