|
|
@@ -37,7 +37,7 @@ function XMPP(options, token) {
|
|
37
|
37
|
this.eventEmitter = new EventEmitter();
|
|
38
|
38
|
this.connection = null;
|
|
39
|
39
|
this.disconnectInProgress = false;
|
|
40
|
|
- this.performanceTimes = {};
|
|
|
40
|
+ this.connectionTimes = {};
|
|
41
|
41
|
this.forceMuted = false;
|
|
42
|
42
|
this.options = options;
|
|
43
|
43
|
initStrophePlugins(this);
|
|
|
@@ -62,7 +62,7 @@ XMPP.prototype.getConnection = function () { return this.connection; };
|
|
62
|
62
|
*/
|
|
63
|
63
|
XMPP.prototype.connectionHandler = function (password, status, msg) {
|
|
64
|
64
|
var now = window.performance.now();
|
|
65
|
|
- this.performanceTimes[Strophe.getStatusString(status).toLowerCase()] = now;
|
|
|
65
|
+ this.connectionTimes[Strophe.getStatusString(status).toLowerCase()] = now;
|
|
66
|
66
|
logger.log("(TIME) Strophe " + Strophe.getStatusString(status) +
|
|
67
|
67
|
(msg ? "[" + msg + "]" : "") + ":\t", now);
|
|
68
|
68
|
if (status === Strophe.Status.CONNECTED ||
|
|
|
@@ -169,7 +169,7 @@ XMPP.prototype._connect = function (jid, password) {
|
|
169
|
169
|
* @param options {object} connecting options - rid, sid, jid and password.
|
|
170
|
170
|
*/
|
|
171
|
171
|
XMPP.prototype.attach = function (options) {
|
|
172
|
|
- var now = this.performanceTimes["attaching"] = window.performance.now();
|
|
|
172
|
+ var now = this.connectionTimes["attaching"] = window.performance.now();
|
|
173
|
173
|
logger.log("(TIME) Strophe Attaching\t:" + now);
|
|
174
|
174
|
this.connection.attach(options.jid, options.sid, parseInt(options.rid,10)+1,
|
|
175
|
175
|
this.connectionHandler.bind(this, options.password));
|