diff options
author | blizzz <blizzz@arthur-schiwon.de> | 2021-06-07 12:12:33 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-06-07 12:12:33 +0200 |
commit | 56b68ce4e07835ecb806bc996e5648e433c5650b (patch) | |
tree | 4df62595b80d2ece7900f4f29fc8cf60f48637ef /apps/user_status/lib/Service | |
parent | 92d19bd79bb9c8c541acabdd29c7cba065a54579 (diff) | |
parent | 55c44580c26aed3185f10eec5e943b8e82166d04 (diff) | |
download | nextcloud-server-56b68ce4e07835ecb806bc996e5648e433c5650b.tar.gz nextcloud-server-56b68ce4e07835ecb806bc996e5648e433c5650b.zip |
Merge pull request #27375 from nextcloud/bugfix/noid/dont-update-offline-status
Don't update statuses to offline again and again
Diffstat (limited to 'apps/user_status/lib/Service')
-rw-r--r-- | apps/user_status/lib/Service/StatusService.php | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/apps/user_status/lib/Service/StatusService.php b/apps/user_status/lib/Service/StatusService.php index 7f77070a87d..f121089ad8e 100644 --- a/apps/user_status/lib/Service/StatusService.php +++ b/apps/user_status/lib/Service/StatusService.php @@ -356,6 +356,10 @@ class StatusService { * @param UserStatus $status */ private function cleanStatus(UserStatus $status): void { + if ($status->getStatus() === IUserStatus::OFFLINE && !$status->getIsUserDefined()) { + return; + } + $status->setStatus(IUserStatus::OFFLINE); $status->setStatusTimestamp($this->timeFactory->getTime()); $status->setIsUserDefined(false); |