Merge pull request #29877 from nextcloud/backport/29869/stable23

This commit is contained in:
Pytal 2021-11-24 11:07:38 -08:00 committed by GitHub
commit 11be6bf4ec
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -127,13 +127,15 @@ class ProfilePageController extends Controller {
}
}
$userStatuses = $this->userStatusManager->getUserStatuses([$targetUserId]);
$status = $userStatuses[$targetUserId] ?? null;
if ($status !== null) {
$this->initialStateService->provideInitialState('status', [
'icon' => $status->getIcon(),
'message' => $status->getMessage(),
]);
if ($visitingUser !== null) {
$userStatuses = $this->userStatusManager->getUserStatuses([$targetUserId]);
$status = $userStatuses[$targetUserId] ?? null;
if ($status !== null) {
$this->initialStateService->provideInitialState('status', [
'icon' => $status->getIcon(),
'message' => $status->getMessage(),
]);
}
}
$this->initialStateService->provideInitialState(