summaryrefslogtreecommitdiffstats
path: root/polygerrit-ui/app/behaviors/gr-anonymous-name-behavior/gr-anonymous-name-behavior.html
diff options
context:
space:
mode:
Diffstat (limited to 'polygerrit-ui/app/behaviors/gr-anonymous-name-behavior/gr-anonymous-name-behavior.html')
-rw-r--r--polygerrit-ui/app/behaviors/gr-anonymous-name-behavior/gr-anonymous-name-behavior.html3
1 files changed, 3 insertions, 0 deletions
diff --git a/polygerrit-ui/app/behaviors/gr-anonymous-name-behavior/gr-anonymous-name-behavior.html b/polygerrit-ui/app/behaviors/gr-anonymous-name-behavior/gr-anonymous-name-behavior.html
index 10065af12e..40379e48ea 100644
--- a/polygerrit-ui/app/behaviors/gr-anonymous-name-behavior/gr-anonymous-name-behavior.html
+++ b/polygerrit-ui/app/behaviors/gr-anonymous-name-behavior/gr-anonymous-name-behavior.html
@@ -1,4 +1,5 @@
<!--
+@license
Copyright (C) 2017 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
@@ -31,6 +32,8 @@ limitations under the License.
getUserName(config, account, enableEmail) {
if (account && account.name) {
return account.name;
+ } else if (account && account.username) {
+ return account.username;
} else if (enableEmail && account && account.email) {
return account.email;
} else if (config && config.user &&