diff --git a/app/assets/javascripts/discourse/controllers/user.js.es6 b/app/assets/javascripts/discourse/controllers/user.js.es6 index 65802be5a..b5151f1b3 100644 --- a/app/assets/javascripts/discourse/controllers/user.js.es6 +++ b/app/assets/javascripts/discourse/controllers/user.js.es6 @@ -41,7 +41,7 @@ export default Ember.Controller.extend(CanCheckEmails, { return viewingSelf || staff; }, - @computed('model.user.name') + @computed('model.name') nameFirst(name) { return !this.get('siteSettings.prioritize_username_in_ux') && name && name.trim().length > 0; }, diff --git a/app/assets/javascripts/discourse/templates/user/user.hbs b/app/assets/javascripts/discourse/templates/user/user.hbs index 4fbca405c..292584ecb 100644 --- a/app/assets/javascripts/discourse/templates/user/user.hbs +++ b/app/assets/javascripts/discourse/templates/user/user.hbs @@ -58,7 +58,7 @@
-

{{if nameFirst model.user model.username}} {{user-status model currentUser=currentUser}}

+

{{if nameFirst model.name model.username}} {{user-status model currentUser=currentUser}}

{{#if nameFirst}}{{model.username}}{{else}}{{model.name}}{{/if}}

{{#if model.title}}

{{model.title}}