quickblox 2.17.5-logger → 2.17.7-logger

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "quickblox",
3
3
  "description": "QuickBlox JavaScript SDK",
4
- "version": "2.17.5-logger",
4
+ "version": "2.17.7-logger",
5
5
  "homepage": "https://quickblox.com/developers/Javascript",
6
6
  "main": "src/qbMain.js",
7
7
  "types": "quickblox.d.ts",
package/quickblox.js CHANGED
@@ -36059,8 +36059,8 @@ function extend() {
36059
36059
  (function (global, factory) {
36060
36060
  typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) :
36061
36061
  typeof define === 'function' && define.amd ? define(['exports'], factory) :
36062
- (global = global || self, factory(global.strophe = {}));
36063
- }(this, (function (exports) { 'use strict';
36062
+ (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global.strophe = {}));
36063
+ })(this, (function (exports) { 'use strict';
36064
36064
 
36065
36065
  var global$1 = typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {};
36066
36066
 
@@ -36253,7 +36253,7 @@ function extend() {
36253
36253
  return WebSocketImplementation;
36254
36254
  }
36255
36255
 
36256
- var WebSocket$1 = getWebSocketImplementation();
36256
+ getWebSocketImplementation();
36257
36257
  /**
36258
36258
  * DOMParser
36259
36259
  * https://w3c.github.io/DOM-Parsing/#the-domparser-interface
@@ -36355,7 +36355,7 @@ function extend() {
36355
36355
  * Add integers, wrapping at 2^32. This uses 16-bit operations internally
36356
36356
  * to work around bugs in some JS interpreters.
36357
36357
  */
36358
- var safe_add = function safe_add(x, y) {
36358
+ var safe_add$1 = function safe_add(x, y) {
36359
36359
  var lsw = (x & 0xFFFF) + (y & 0xFFFF);
36360
36360
  var msw = (x >> 16) + (y >> 16) + (lsw >> 16);
36361
36361
  return msw << 16 | lsw & 0xFFFF;
@@ -36421,7 +36421,7 @@ function extend() {
36421
36421
 
36422
36422
 
36423
36423
  var md5_cmn = function md5_cmn(q, a, b, x, s, t) {
36424
- return safe_add(bit_rol(safe_add(safe_add(a, q), safe_add(x, t)), s), b);
36424
+ return safe_add$1(bit_rol(safe_add$1(safe_add$1(a, q), safe_add$1(x, t)), s), b);
36425
36425
  };
36426
36426
 
36427
36427
  var md5_ff = function md5_ff(a, b, c, d, x, s, t) {
@@ -36523,10 +36523,10 @@ function extend() {
36523
36523
  d = md5_ii(d, a, b, c, x[i + 11], 10, -1120210379);
36524
36524
  c = md5_ii(c, d, a, b, x[i + 2], 15, 718787259);
36525
36525
  b = md5_ii(b, c, d, a, x[i + 9], 21, -343485551);
36526
- a = safe_add(a, olda);
36527
- b = safe_add(b, oldb);
36528
- c = safe_add(c, oldc);
36529
- d = safe_add(d, oldd);
36526
+ a = safe_add$1(a, olda);
36527
+ b = safe_add$1(b, oldb);
36528
+ c = safe_add$1(c, oldc);
36529
+ d = safe_add$1(d, oldd);
36530
36530
  }
36531
36531
 
36532
36532
  return [a, b, c, d];
@@ -36589,7 +36589,7 @@ function extend() {
36589
36589
  w[j] = rol(w[j - 3] ^ w[j - 8] ^ w[j - 14] ^ w[j - 16], 1);
36590
36590
  }
36591
36591
 
36592
- t = safe_add$1(safe_add$1(rol(a, 5), sha1_ft(j, b, c, d)), safe_add$1(safe_add$1(e, w[j]), sha1_kt(j)));
36592
+ t = safe_add(safe_add(rol(a, 5), sha1_ft(j, b, c, d)), safe_add(safe_add(e, w[j]), sha1_kt(j)));
36593
36593
  e = d;
36594
36594
  d = c;
36595
36595
  c = rol(b, 30);
@@ -36597,11 +36597,11 @@ function extend() {
36597
36597
  a = t;
36598
36598
  }
36599
36599
 
36600
- a = safe_add$1(a, olda);
36601
- b = safe_add$1(b, oldb);
36602
- c = safe_add$1(c, oldc);
36603
- d = safe_add$1(d, oldd);
36604
- e = safe_add$1(e, olde);
36600
+ a = safe_add(a, olda);
36601
+ b = safe_add(b, oldb);
36602
+ c = safe_add(c, oldc);
36603
+ d = safe_add(d, oldd);
36604
+ e = safe_add(e, olde);
36605
36605
  }
36606
36606
 
36607
36607
  return [a, b, c, d, e];
@@ -36664,7 +36664,7 @@ function extend() {
36664
36664
  */
36665
36665
 
36666
36666
 
36667
- function safe_add$1(x, y) {
36667
+ function safe_add(x, y) {
36668
36668
  var lsw = (x & 0xFFFF) + (y & 0xFFFF);
36669
36669
  var msw = (x >> 16) + (y >> 16) + (lsw >> 16);
36670
36670
  return msw << 16 | lsw & 0xFFFF;
@@ -42928,7 +42928,7 @@ function extend() {
42928
42928
 
42929
42929
  Object.defineProperty(exports, '__esModule', { value: true });
42930
42930
 
42931
- })));
42931
+ }));
42932
42932
 
42933
42933
  }).call(this)}).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
42934
42934
  },{"ws":225,"xmldom":undefined}],228:[function(require,module,exports){
@@ -43352,12 +43352,12 @@ function ChatProxy(service) {
43352
43352
  }
43353
43353
 
43354
43354
  // MUC presences go here
43355
- if (xXMLNS && xXMLNS == "http://jabber.org/protocol/muc#user") {
43355
+ if (xXMLNS && xXMLNS == 'http://jabber.org/protocol/muc#user') {
43356
43356
  dialogId = self.helpers.getDialogIdFromNode(from);
43357
43357
  userId = self.helpers.getUserIdFromRoomJid(from);
43358
43358
 
43359
43359
  // KICK from dialog event
43360
- if (status && statusCode == "301") {
43360
+ if (status && statusCode == '301') {
43361
43361
  if (typeof self.onKickOccupant === 'function') {
43362
43362
  var actorElement = chatUtils.getElement(chatUtils.getElement(x, 'item'), 'actor');
43363
43363
  var initiatorUserJid = chatUtils.getAttr(actorElement, 'jid');
@@ -43813,7 +43813,7 @@ ChatProxy.prototype = {
43813
43813
  self.isConnected = false;
43814
43814
  self._isConnecting = false;
43815
43815
  self._chatPingFailedCounter = 0;
43816
- self._establishConnection(params);
43816
+ self._establishConnection(params,'CONNECTED have SDK ping failed');
43817
43817
  }
43818
43818
  } else {
43819
43819
  Utils.QBLog('[QBChat]',
@@ -43885,7 +43885,7 @@ ChatProxy.prototype = {
43885
43885
  self.connection.reset();
43886
43886
 
43887
43887
  // reconnect to chat and enable check connection
43888
- self._establishConnection(params);
43888
+ self._establishConnection(params,'DISCONNECTED');
43889
43889
 
43890
43890
  break;
43891
43891
  case Strophe.Status.ATTACHED:
@@ -44014,7 +44014,7 @@ ChatProxy.prototype = {
44014
44014
  self._isConnecting = false;
44015
44015
 
44016
44016
  // reconnect to chat and enable check connection
44017
- self._establishConnection(params);
44017
+ self._establishConnection(params,'NODE:DISCONNECTED');
44018
44018
  });
44019
44019
 
44020
44020
  self.Client.on('error', function () {
@@ -44096,39 +44096,39 @@ ChatProxy.prototype = {
44096
44096
  }
44097
44097
  },
44098
44098
 
44099
- _establishConnection: function (params) {
44099
+ _establishConnection: function (params, description) {
44100
44100
  var self = this;
44101
- Utils.QBLog('[QBChat]', '_establishConnection called');
44101
+ Utils.QBLog('[QBChat]', '_establishConnection called in ' + description);
44102
44102
  if (typeof self.onLogListener === 'function') {
44103
44103
  Utils.safeCallbackCall(self.onLogListener,
44104
- '[QBChat]' + '_establishConnection called');
44104
+ '[QBChat]' + '_establishConnection called in ' + description);
44105
44105
  }
44106
44106
  if (self._isLogout || self._checkConnectionTimer) {
44107
44107
  Utils.QBLog('[QBChat]', '_establishConnection return');
44108
44108
  if (typeof self.onLogListener === 'function') {
44109
44109
  Utils.safeCallbackCall(self.onLogListener,
44110
- '[QBChat]' + ' _establishConnection return with self._isLogout: '+
44111
- self._isLogout+' and self._checkConnectionTimer ' +self._checkConnectionTimer?'set up':'undefined');
44110
+ '[QBChat]' + 'BREAK _establishConnection RETURN with self._isLogout: '+
44111
+ self._isLogout?self._isLogout:'undefined'+' and self._checkConnectionTimer ' +self._checkConnectionTimer?self._checkConnectionTimer:'undefined');
44112
44112
  }
44113
44113
  return;
44114
44114
  }
44115
44115
 
44116
44116
  var _connect = function () {
44117
- Utils.QBLog('[QBChat]', 'call _connect() in _establishConnection ');
44117
+ Utils.QBLog('[QBChat]', 'call _connect() in _establishConnection in '+description);
44118
44118
  if (typeof self.onLogListener === 'function') {
44119
44119
  Utils.safeCallbackCall(self.onLogListener,
44120
- '[QBChat]' + ' call _connect() in _establishConnection ');
44120
+ '[QBChat]' + ' call _connect() in _establishConnection in '+description);
44121
44121
  }
44122
44122
  if (!self.isConnected && !self._isConnecting && !self._sessionHasExpired) {
44123
- Utils.QBLog('[QBChat]', ' start execute connect() in _establishConnection ');
44123
+ Utils.QBLog('[QBChat]', ' start EXECUTE connect() in _establishConnection ');
44124
44124
  if (typeof self.onLogListener === 'function') {
44125
44125
  Utils.safeCallbackCall(self.onLogListener,
44126
- '[QBChat]' + ' with statuses (!self.isConnected && !self._isConnecting && !self._sessionHasExpired): '+' self.isConnected: '+self.isConnected+' self._isConnecting: '+self._isConnecting+' self._sessionHasExpired: '+self._sessionHasExpired);
44126
+ '[QBChat]' + ' start EXECUTE connect() in _establishConnection in '+description+' self.isConnected: '+self.isConnected+' self._isConnecting: '+self._isConnecting+' self._sessionHasExpired: '+self._sessionHasExpired);
44127
44127
  }
44128
44128
  self.connect(params);
44129
44129
  if (typeof self.onLogListener === 'function') {
44130
44130
  Utils.safeCallbackCall(self.onLogListener,
44131
- '[QBChat]' + 'call _connect() in _establishConnection is executed');
44131
+ '[QBChat]' + 'call _connect() in _establishConnection in '+description+' is executed');
44132
44132
  }
44133
44133
  } else {
44134
44134
  Utils.QBLog('[QBChat]', 'stop timer in _establishConnection ');
@@ -44136,7 +44136,7 @@ ChatProxy.prototype = {
44136
44136
  self._checkConnectionTimer = undefined;
44137
44137
  if (typeof self.onLogListener === 'function') {
44138
44138
  Utils.safeCallbackCall(self.onLogListener,
44139
- '[QBChat]' + 'stop timer in _establishConnection ');
44139
+ '[QBChat]' + 'stop timer in _establishConnection in '+description);
44140
44140
  }
44141
44141
  }
44142
44142
  };
@@ -51484,7 +51484,7 @@ module.exports = StreamManagement;
51484
51484
  */
51485
51485
 
51486
51486
  var config = {
51487
- version: '2.17.5-logger',
51487
+ version: '2.17.7-logger',
51488
51488
  buildNumber: '1161',
51489
51489
  creds: {
51490
51490
  'appId': 0,
@@ -52207,6 +52207,10 @@ function Connection(onLogListener) {
52207
52207
  if (data.childNodes[0]) {
52208
52208
  for (var i = 0, len = data.childNodes.length; i < len; i++) {
52209
52209
  Utils.QBLog('[QBChat]', 'RECV:', data.childNodes[i]);
52210
+ if (onLogListener && typeof onLogListener === 'function') {
52211
+ Utils.safeCallbackCall(onLogListener,
52212
+ '[QBChat][QBStrophe]' + 'RECV:' + data.childNodes[i]);
52213
+ }
52210
52214
  }
52211
52215
  }
52212
52216
  };
@@ -52214,13 +52218,20 @@ function Connection(onLogListener) {
52214
52218
  if (data.childNodes[0]) {
52215
52219
  for (var i = 0, len = data.childNodes.length; i < len; i++) {
52216
52220
  Utils.QBLog('[QBChat]', 'SENT:', data.childNodes[i]);
52221
+ if (onLogListener && typeof onLogListener === 'function') {
52222
+ Utils.safeCallbackCall(onLogListener,
52223
+ '[QBChat][QBStrophe]' + 'SENT:' + data.childNodes[i]);
52224
+ }
52217
52225
  }
52218
52226
  }
52219
52227
  };
52220
52228
  } else {
52221
52229
  conn.xmlInput = function(data) {
52222
52230
  Utils.QBLog('[QBChat]', 'RECV:', data);
52223
- //
52231
+ if (onLogListener && typeof onLogListener === 'function') {
52232
+ Utils.safeCallbackCall(onLogListener,
52233
+ '[QBChat][QBStrophe]' + 'RECV:' + data);
52234
+ }
52224
52235
  try {
52225
52236
  let parser = new DOMParser();
52226
52237
  let xmlDoc = parser.parseFromString(data, 'text/xml');
@@ -52240,10 +52251,13 @@ function Connection(onLogListener) {
52240
52251
  } catch (e) {
52241
52252
  console.error('Error parsing XML input:', e);
52242
52253
  }
52243
- //
52244
52254
  };
52245
52255
  conn.xmlOutput = function(data) {
52246
52256
  Utils.QBLog('[QBChat]', 'SENT:', data);
52257
+ if (onLogListener && typeof onLogListener === 'function') {
52258
+ Utils.safeCallbackCall(onLogListener,
52259
+ '[QBChat][QBStrophe]' + 'SENT:' + data);
52260
+ }
52247
52261
  };
52248
52262
  }
52249
52263