Skip to content
This repository was archived by the owner on May 16, 2019. It is now read-only.

Commit e565e7a

Browse files
committed
fixing issue where first notifications not rendered in UI
1 parent 965f6e7 commit e565e7a

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

js/views/notificationsVw.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,11 @@ module.exports = baseVw.extend({
2222
this.fetch = this.options.initialFetch;
2323

2424
this.listenTo(this.collection, 'update', (cl, options) => {
25+
if (!options.add) return;
26+
27+
// on first notification, we'll re-render
28+
if (cl.length === 1) this.render();
29+
2530
var $notifPage = $('<div />');
2631

2732
// we're assuming the only additions will either be a batch of

0 commit comments

Comments
 (0)