Skip to content

Commit

Permalink
Final dirty diff cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
riking committed Sep 9, 2014
1 parent 69bc552 commit 5994b63
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
4 changes: 3 additions & 1 deletion app/assets/javascripts/discourse/models/notification.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,12 @@ Discourse.NotificationContainer.reopenClass({
},

loadRecent: function() {
// TODO - add .json (breaks tests atm)
return Discourse.ajax('/notifications').then(function(result) {
return Discourse.NotificationContainer.createFromJson(result);
}).catch(function(error) {
// HeaderController can't handle it properly
// TODO HeaderController can't handle a createFromError
// just throw for now
throw error;
});
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,7 @@
</li>
</ul>
{{else}}
{{#if error}}
<div class="none error">{{i18n notifications.none}}</div>
{{else}}
<div class="none">{{i18n notifications.none}}</div>
{{/if}}
<div class="none">{{i18n notifications.none}}</div>
{{/if}}
{{else}}
<div class='loading'><i class='fa fa-spinner fa-spin'></i></div>
Expand Down

0 comments on commit 5994b63

Please sign in to comment.