diff options
-rw-r--r-- | core/templates/layout.user.php | 2 | ||||
-rw-r--r-- | lib/template.php | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/core/templates/layout.user.php b/core/templates/layout.user.php index 0d2a9f5d34a..2d00bdb5c8e 100644 --- a/core/templates/layout.user.php +++ b/core/templates/layout.user.php @@ -31,7 +31,7 @@ <ul id="settings" class="svg"> <span id="expand"> - <?php echo OCP\User::getDisplayName($user=null)?OC_Util::sanitizeHTML(OCP\User::getDisplayName($user=null)):(OC_User::getUser()?OC_User::getUser():'') ?> + <?php echo $_['displayname'] ?> <img class="svg" src="<?php echo image_path('', 'actions/caret.svg'); ?>" /> </span> <div id="expanddiv"> diff --git a/lib/template.php b/lib/template.php index 0230d2f9343..3df5a24f946 100644 --- a/lib/template.php +++ b/lib/template.php @@ -415,6 +415,8 @@ class OC_Template{ $page = new OC_TemplateLayout($this->renderas); if($this->renderas == 'user') { $page->assign('requesttoken', $this->vars['requesttoken']); + $user = OC_User::getUser(); + $page->assign('displayname', OCP\User::getDisplayName($user)); } // Add custom headers |