correct broken logic in screen track that was causing read status not to flush properly when navigating using the suggested topics list.

This commit is contained in:
Sam 2013-08-19 11:35:06 +10:00
parent 4b0a1179e9
commit 9b5da77855
1 changed files with 5 additions and 5 deletions

View File

@ -14,6 +14,11 @@ Discourse.ScreenTrack = Ember.Object.extend({
},
start: function(topicId) {
var currentTopicId = this.get('topicId');
if (currentTopicId && (currentTopicId !== topicId)) {
this.tick();
this.flush();
}
this.reset();
@ -25,11 +30,6 @@ Discourse.ScreenTrack = Ember.Object.extend({
}, 1000));
}
var currentTopicId = this.get('topicId');
if (currentTopicId && (currentTopicId !== topicId)) {
this.flush();
this.reset();
}
this.set('topicId', topicId);
},