This commit is contained in:
Sam 2014-09-11 11:15:49 +10:00
parent 5cb7c8ee11
commit 306d31b92e
2 changed files with 4 additions and 3 deletions

View File

@ -25,8 +25,8 @@ Discourse.UserStream = Discourse.Model.extend({
}
if(!filter) {
return [Discourse.UserAction.TYPES.posts,
Discourse.UserAction.TYPES.topics];
return [ Discourse.UserAction.TYPES.topics,
Discourse.UserAction.TYPES.posts].join(",");
}
return filter;

View File

@ -18,7 +18,8 @@ test('filterParam', function() {
var user = Discourse.User.create({id: 1, username: 'eviltrout'});
var stream = user.get('stream');
blank(stream.get('filterParam'), "it's blank by default");
// defaults to posts/topics
equal(stream.get('filterParam'), "4,5");
stream.set('filter', Discourse.UserAction.TYPES.likes_given);
equal(stream.get('filterParam'), Discourse.UserAction.TYPES.likes_given);