mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
Upgrade ember qunit, create new interface for testing components
This commit is contained in:
@@ -103,7 +103,7 @@ const PostMenuComponent = Ember.Component.extend(StringBuffer, {
|
||||
|
||||
const replyCount = post.get('reply_count');
|
||||
buffer.push("<button class='show-replies highlight-action' data-action='replies'>");
|
||||
buffer.push(I18n.t("post.has_replies", { count: replyCount }));
|
||||
buffer.push(I18n.t("post.has_replies", { count: replyCount || 0 }));
|
||||
|
||||
const icon = (this.get('post.replies.length') > 0) ? 'chevron-up' : 'chevron-down';
|
||||
return buffer.push(iconHTML(icon) + "</button>");
|
||||
|
||||
@@ -70,7 +70,7 @@ const Topic = RestModel.extend({
|
||||
}.property('url'),
|
||||
|
||||
url: function() {
|
||||
let slug = this.get('slug');
|
||||
let slug = this.get('slug') || '';
|
||||
if (slug.trim().length === 0) {
|
||||
slug = "topic";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user