FIX: Private messages were getting the has-category style

This commit is contained in:
Robin Ward 2014-10-08 12:59:00 -04:00
parent 1f26a79899
commit a98b8251a6
2 changed files with 6 additions and 1 deletions

View file

@ -10,6 +10,11 @@ export default DiscourseController.extend({
loginRequired: Em.computed.alias('controllers.application.loginRequired'),
canSignUp: Em.computed.alias('controllers.application.canSignUp'),
hasCategory: function() {
var cat = this.get('topic.category');
return cat && !cat.get('isUncategorizedCategory');
}.property('topic.category'),
showPrivateMessageGlyph: function() {
return !this.get('topic.is_warning') && this.get('topic.isPrivateMessage');
}.property('topic.is_warning', 'topic.isPrivateMessage'),

View file

@ -94,7 +94,7 @@
{{#if showExtraInfo}}
<div class="extra-info-wrapper">
<div {{bind-attr class=":extra-info topic.category.isUncategorizedCategory::has-category"}}>
<div {{bind-attr class=":extra-info hasCategory"}}>
{{#if showStarButton}}
<a {{bind-attr class=":star topic.starred:starred"}} {{action "toggleStar"}} href='#' {{bind-attr title="topic.starTooltip"}}></a>
{{/if}}