Micro refactor group update setup in message view

This commit is contained in:
lilia 2015-01-21 13:53:01 -10:00
parent bea19e7997
commit 8097db9af7

View file

@ -37,11 +37,12 @@
className: "entry",
initialize: function() {
var groupUpdate = this.model.get('group_update');
this.$el.addClass(this.model.get('type'));
if (this.model.get('group_update')) {
if (groupUpdate) {
this.group_update_view = new Whisper.GroupUpdateView({
model: this.model.get('group_update')
model: groupUpdate
}).render();
} else {
this.template = $('#message').html();