summaryrefslogtreecommitdiff
path: root/program/include/rcube_template.php
diff options
context:
space:
mode:
Diffstat (limited to 'program/include/rcube_template.php')
-rwxr-xr-xprogram/include/rcube_template.php8
1 files changed, 6 insertions, 2 deletions
diff --git a/program/include/rcube_template.php b/program/include/rcube_template.php
index 4dcabb9a1..d923c6478 100755
--- a/program/include/rcube_template.php
+++ b/program/include/rcube_template.php
@@ -994,15 +994,19 @@ class rcube_template extends rcube_html_page
return $username;
}
+ // Current username is an e-mail address
+ if (strpos($_SESSION['username'], '@')) {
+ $username = $_SESSION['username'];
+ }
// get e-mail address from default identity
- if ($sql_arr = $this->app->user->get_identity()) {
+ else if ($sql_arr = $this->app->user->get_identity()) {
$username = $sql_arr['email'];
}
else {
$username = $this->app->user->get_username();
}
- return $username;
+ return idn_to_utf8($username);
}