Micro refactor group update setup in message view
This commit is contained in:
parent
bea19e7997
commit
8097db9af7
1 changed files with 3 additions and 2 deletions
|
@ -37,11 +37,12 @@
|
||||||
className: "entry",
|
className: "entry",
|
||||||
|
|
||||||
initialize: function() {
|
initialize: function() {
|
||||||
|
var groupUpdate = this.model.get('group_update');
|
||||||
this.$el.addClass(this.model.get('type'));
|
this.$el.addClass(this.model.get('type'));
|
||||||
|
|
||||||
if (this.model.get('group_update')) {
|
if (groupUpdate) {
|
||||||
this.group_update_view = new Whisper.GroupUpdateView({
|
this.group_update_view = new Whisper.GroupUpdateView({
|
||||||
model: this.model.get('group_update')
|
model: groupUpdate
|
||||||
}).render();
|
}).render();
|
||||||
} else {
|
} else {
|
||||||
this.template = $('#message').html();
|
this.template = $('#message').html();
|
||||||
|
|
Loading…
Reference in a new issue