diff options
author | Joas Schilling <coding@schilljs.com> | 2022-05-27 09:15:15 +0200 |
---|---|---|
committer | backportbot-nextcloud[bot] <backportbot-nextcloud[bot]@users.noreply.github.com> | 2022-05-27 09:23:54 +0000 |
commit | 421cbde0eb748965e6335c6d5772df4f8f6fdcf8 (patch) | |
tree | 9635c5cb015b5f4843746813e4e2c14832aa8a09 /apps | |
parent | 31235cb191581a7d3222589ecd260da4f7e4a5b9 (diff) | |
download | nextcloud-server-421cbde0eb748965e6335c6d5772df4f8f6fdcf8.tar.gz nextcloud-server-421cbde0eb748965e6335c6d5772df4f8f6fdcf8.zip |
Fix missing status with predefined status in drop-down
When a predefined status message was used, the status was not "processed"
so it was missing the translated message and the icon in the dropdown and the menu afterwards
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'apps')
-rw-r--r-- | apps/user_status/lib/Listener/UserLiveStatusListener.php | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/apps/user_status/lib/Listener/UserLiveStatusListener.php b/apps/user_status/lib/Listener/UserLiveStatusListener.php index c015e684142..3e05efa7118 100644 --- a/apps/user_status/lib/Listener/UserLiveStatusListener.php +++ b/apps/user_status/lib/Listener/UserLiveStatusListener.php @@ -43,11 +43,14 @@ use OCP\UserStatus\IUserStatus; */ class UserLiveStatusListener implements IEventListener { private UserStatusMapper $mapper; + private StatusService $statusService; private ITimeFactory $timeFactory; public function __construct(UserStatusMapper $mapper, + StatusService $statusService, ITimeFactory $timeFactory) { $this->mapper = $mapper; + $this->statusService = $statusService; $this->timeFactory = $timeFactory; } @@ -62,7 +65,7 @@ class UserLiveStatusListener implements IEventListener { $user = $event->getUser(); try { - $userStatus = $this->mapper->findByUserId($user->getUID()); + $userStatus = $this->statusService->findByUserId($user->getUID()); } catch (DoesNotExistException $ex) { $userStatus = new UserStatus(); $userStatus->setUserId($user->getUID()); |