Commit 5a2b22ff authored by movilla's avatar movilla

reshares_count come back!

parent a78cacb7
......@@ -36,6 +36,7 @@
* Fix empty page after authenticating with other services. [#3693](https://github.com/diaspora/diaspora/pull/3693)
* Fix posting public posts to Facebook. [#2882](https://github.com/diaspora/diaspora/issues/2882), [#3650](https://github.com/diaspora/diaspora/issues/3650)
* Fix error with invite link box shows on search results page even if invites have been turned off. [#3708](https://github.com/diaspora/diaspora/pull/3708)
* Fix problem with show reshares_count in stream. [#3700](https://github.com/diaspora/diaspora/pull/3700)
# 0.0.1.2
......
......@@ -23,9 +23,9 @@
<time class="timeago" datetime="{{created_at}}"/>
</a>
{{#if reshares_count}}
{{#if interactions.reshares_count}}
-
{{t "stream.reshares" count=reshares_count}}
{{t "stream.reshares" count=interactions.reshares_count}}
{{/if}}
</span>
</div>
......
......@@ -37,9 +37,9 @@
<time class="timeago" datetime="{{created_at}}" />
</a>
{{#if reshares_count}}
{{#if interactions.reshares_count}}
-
{{t "stream.reshares" count=reshares_count}}
{{t "stream.reshares" count=interactions.reshares_count}}
{{/if}}
</span>
</div>
......
......@@ -28,19 +28,19 @@ describe("app.views.StreamPost", function(){
context("reshare", function(){
it("displays a reshare count", function(){
this.statusMessage.set({reshares_count : 2})
this.statusMessage.set({ interactions: {reshares_count : 2 }});
var view = new this.PostViewClass({model : this.statusMessage}).render();
expect($(view.el).html()).toContain(Diaspora.I18n.t('stream.reshares', {count: 2}))
})
expect($(view.el).html()).toContain(Diaspora.I18n.t('stream.reshares', {count: 2}));
});
it("does not display a reshare count for 'zero'", function(){
this.statusMessage.set({reshares_count : 0})
this.statusMessage.interactions.set({ interactions: { reshares_count : 0}} );
var view = new this.PostViewClass({model : this.statusMessage}).render();
expect($(view.el).html()).not.toContain("0 Reshares")
})
})
expect($(view.el).html()).not.toContain("0 Reshares");
});
});
context("likes", function(){
it("displays a like count", function(){
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment