From c4cafb8c4f4939e8872759a5fab1c6c8735fe47f Mon Sep 17 00:00:00 2001 From: ichim-david Date: Sat, 2 Mar 2013 09:32:26 +0200 Subject: [PATCH] Changed the following: - Chain calls on initialize method of RosterView - Moved dom insertion out of loops on initialize method of XMPPStatusView --- converse.js | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/converse.js b/converse.js index ae6079c36..212f9d1fb 100644 --- a/converse.js +++ b/converse.js @@ -1531,7 +1531,7 @@ } else if (presence_type === 'subscribe') { item = this.getItem(bare_jid); - // TODO see which auto_subscribe is seen as unresolved variable + // TODO see if auto_subscribe is truly an unresolved variable if (xmppchat.auto_subscribe) { if ((!item) || (item.get('subscription') != 'to')) { if (xmppchat.connection.roster.findItem(bare_jid)) { @@ -1633,8 +1633,8 @@ delete this.rosteritemviews[item.id]; }, this); - this.$el.hide(); - this.$el.html(this.template()); + this.$el.hide() + .html(this.template()); }, template: _.template('
Contact requests
' + @@ -1843,6 +1843,8 @@ var $select = this.$el.find('select#select-xmpp-status'), presence_type = this.model.getStatus() || 'offline', options = $('option', $select), + $options_target, + options_list = [], that = this; this.$el.html(this.choose_template()); this.$el.find('#fancy-xmpp-status-select') @@ -1850,13 +1852,15 @@ 'status_message': "I am " + presence_type, 'presence_type': presence_type })); - // iterate through all the