aboutsummaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
authorVincent Petry <vincent@nextcloud.com>2022-04-07 17:40:26 +0200
committerGitHub <noreply@github.com>2022-04-07 17:40:26 +0200
commit462a43ac2b4879a369d2c7d36925aafe18d1f796 (patch)
tree8a8e8679f81ef16182f70037f768fa6463e41267 /core
parent4bb8e9472eb4459f9a5e3d6522fbb5df370b0573 (diff)
parentddc739b5ac2bb5f54fdb47db6a3e0dfe83d1c473 (diff)
downloadnextcloud-server-462a43ac2b4879a369d2c7d36925aafe18d1f796.tar.gz
nextcloud-server-462a43ac2b4879a369d2c7d36925aafe18d1f796.zip
Merge pull request #31847 from nextcloud/performance/user-status-retrival
Retrieve user status only once when displaying page
Diffstat (limited to 'core')
-rw-r--r--core/templates/layout.user.php6
1 files changed, 1 insertions, 5 deletions
diff --git a/core/templates/layout.user.php b/core/templates/layout.user.php
index ce316b882e6..2b84c89fca6 100644
--- a/core/templates/layout.user.php
+++ b/core/templates/layout.user.php
@@ -153,11 +153,7 @@ $getUserAvatar = static function (int $size) use ($_): string {
} ?>"
data-user="<?php p($_['user_uid']); ?>"
data-displayname="<?php p($_['user_displayname']); ?>"
- <?php if ($_['userStatus'] !== false) { ?>
- data-userstatus="<?php p($_['userStatus']->getStatus()); ?>"
- data-userstatus_message="<?php p($_['userStatus']->getMessage()); ?>"
- data-userstatus_icon="<?php p($_['userStatus']->getIcon()); ?>"
- <?php }
+ <?php
if ($_['userAvatarSet']) {
$avatar32 = $getUserAvatar(32); ?> data-avatar="<?php p($avatar32); ?>"
<?php