stream-chat 5.0.1 → 5.2.0

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/dist/index.es.js CHANGED
@@ -89,7 +89,7 @@ var decodeBase64 = function decodeBase64(s) {
89
89
  return r;
90
90
  };
91
91
 
92
- function ownKeys$7(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
92
+ function ownKeys$7(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
93
93
 
94
94
  function _objectSpread$7(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys$7(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys$7(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
95
95
 
@@ -312,6 +312,12 @@ var ChannelState = /*#__PURE__*/function () {
312
312
  for (var i = 0; i < newMessages.length; i += 1) {
313
313
  var _this$_channel;
314
314
 
315
+ var isFromShadowBannedUser = newMessages[i].shadowed;
316
+
317
+ if (isFromShadowBannedUser) {
318
+ continue;
319
+ }
320
+
315
321
  var message = this.formatMessage(newMessages[i]);
316
322
 
317
323
  if (message.user && (_this$_channel = this._channel) !== null && _this$_channel !== void 0 && _this$_channel.cid) {
@@ -701,7 +707,7 @@ var ChannelState = /*#__PURE__*/function () {
701
707
  return ChannelState;
702
708
  }();
703
709
 
704
- function ownKeys$6(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
710
+ function ownKeys$6(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
705
711
 
706
712
  function _objectSpread$6(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys$6(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys$6(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
707
713
 
@@ -709,6 +715,7 @@ var EVENT_MAP = {
709
715
  'channel.created': true,
710
716
  'channel.deleted': true,
711
717
  'channel.hidden': true,
718
+ 'channel.kicked': true,
712
719
  'channel.muted': true,
713
720
  'channel.truncated': true,
714
721
  'channel.unmuted': true,
@@ -758,7 +765,7 @@ var isValidEventType = function isValidEventType(eventType) {
758
765
  return IS_VALID_EVENT_MAP_TYPE[eventType] || false;
759
766
  };
760
767
 
761
- function _createForOfIteratorHelper$3(o, allowArrayLike) { var it; if (typeof Symbol === "undefined" || o[Symbol.iterator] == null) { if (Array.isArray(o) || (it = _unsupportedIterableToArray$3(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function (_e) { function e(_x) { return _e.apply(this, arguments); } e.toString = function () { return _e.toString(); }; return e; }(function (e) { throw e; }), f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = o[Symbol.iterator](); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function (_e2) { function e(_x2) { return _e2.apply(this, arguments); } e.toString = function () { return _e2.toString(); }; return e; }(function (e) { didErr = true; err = e; }), f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }
768
+ function _createForOfIteratorHelper$3(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray$3(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function (_e) { function e(_x) { return _e.apply(this, arguments); } e.toString = function () { return _e.toString(); }; return e; }(function (e) { throw e; }), f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function (_e2) { function e(_x2) { return _e2.apply(this, arguments); } e.toString = function () { return _e2.toString(); }; return e; }(function (e) { didErr = true; err = e; }), f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }
762
769
 
763
770
  function _unsupportedIterableToArray$3(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray$3(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$3(o, minLen); }
764
771
 
@@ -804,6 +811,10 @@ function isFileWebAPI(uri) {
804
811
  return typeof window !== 'undefined' && 'File' in window && uri instanceof File;
805
812
  }
806
813
 
814
+ function isBlobWebAPI(uri) {
815
+ return typeof window !== 'undefined' && 'Blob' in window && uri instanceof Blob;
816
+ }
817
+
807
818
  function isOwnUser(user) {
808
819
  return (user === null || user === void 0 ? void 0 : user.total_unread_count) !== undefined;
809
820
  }
@@ -823,7 +834,7 @@ function isOwnUserBaseProperty(property) {
823
834
  function addFileToFormData(uri, name, contentType) {
824
835
  var data = new FormData();
825
836
 
826
- if (isReadableStream(uri) || isBuffer(uri) || isFileWebAPI(uri)) {
837
+ if (isReadableStream(uri) || isBuffer(uri) || isFileWebAPI(uri) || isBlobWebAPI(uri)) {
827
838
  if (name) data.append('file', uri, name);else data.append('file', uri);
828
839
  } else {
829
840
  data.append('file', {
@@ -984,13 +995,13 @@ function removeConnectionEventListeners(cb) {
984
995
  }
985
996
  }
986
997
 
987
- function _createForOfIteratorHelper$2(o, allowArrayLike) { var it; if (typeof Symbol === "undefined" || o[Symbol.iterator] == null) { if (Array.isArray(o) || (it = _unsupportedIterableToArray$2(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = o[Symbol.iterator](); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }
998
+ function _createForOfIteratorHelper$2(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray$2(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }
988
999
 
989
1000
  function _unsupportedIterableToArray$2(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray$2(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$2(o, minLen); }
990
1001
 
991
1002
  function _arrayLikeToArray$2(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
992
1003
 
993
- function ownKeys$5(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
1004
+ function ownKeys$5(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
994
1005
 
995
1006
  function _objectSpread$5(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys$5(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys$5(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
996
1007
 
@@ -2575,6 +2586,50 @@ var Channel = /*#__PURE__*/function () {
2575
2586
 
2576
2587
  return getReplies;
2577
2588
  }()
2589
+ /**
2590
+ * getPinnedMessages - List list pinned messages of the channel
2591
+ *
2592
+ * @param {PinnedMessagePaginationOptions & { user?: UserResponse<UserType>; user_id?: string }} options Pagination params, ie {limit:10, id_lte: 10}
2593
+ * @param {PinnedMessagesSort} sort defines sorting direction of pinned messages
2594
+ *
2595
+ * @return {Promise<GetRepliesAPIResponse<AttachmentType, ChannelType, CommandType, MessageType, ReactionType, UserType>>} A response with a list of messages
2596
+ */
2597
+
2598
+ }, {
2599
+ key: "getPinnedMessages",
2600
+ value: function () {
2601
+ var _getPinnedMessages = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee30(options) {
2602
+ var sort,
2603
+ _args30 = arguments;
2604
+ return _regeneratorRuntime.wrap(function _callee30$(_context30) {
2605
+ while (1) {
2606
+ switch (_context30.prev = _context30.next) {
2607
+ case 0:
2608
+ sort = _args30.length > 1 && _args30[1] !== undefined ? _args30[1] : [];
2609
+ _context30.next = 3;
2610
+ return this.getClient().get(this.getClient().baseURL + "/channels/".concat(this.type, "/").concat(this.id, "/pinned_messages"), {
2611
+ payload: _objectSpread$5(_objectSpread$5({}, options), {}, {
2612
+ sort: normalizeQuerySort(sort)
2613
+ })
2614
+ });
2615
+
2616
+ case 3:
2617
+ return _context30.abrupt("return", _context30.sent);
2618
+
2619
+ case 4:
2620
+ case "end":
2621
+ return _context30.stop();
2622
+ }
2623
+ }
2624
+ }, _callee30, this);
2625
+ }));
2626
+
2627
+ function getPinnedMessages(_x29) {
2628
+ return _getPinnedMessages.apply(this, arguments);
2629
+ }
2630
+
2631
+ return getPinnedMessages;
2632
+ }()
2578
2633
  /**
2579
2634
  * getReactions - List the reactions, supports pagination
2580
2635
  *
@@ -2702,13 +2757,13 @@ var Channel = /*#__PURE__*/function () {
2702
2757
  * @return {Promise<ChannelAPIResponse<AttachmentType, ChannelType, CommandType, MessageType, ReactionType, UserType>>} Returns a query response
2703
2758
  */
2704
2759
  function () {
2705
- var _query = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee30(options) {
2760
+ var _query = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee31(options) {
2706
2761
  var queryURL, state, membersStr, tempChannelCid;
2707
- return _regeneratorRuntime.wrap(function _callee30$(_context30) {
2762
+ return _regeneratorRuntime.wrap(function _callee31$(_context31) {
2708
2763
  while (1) {
2709
- switch (_context30.prev = _context30.next) {
2764
+ switch (_context31.prev = _context31.next) {
2710
2765
  case 0:
2711
- _context30.next = 2;
2766
+ _context31.next = 2;
2712
2767
  return this.getClient().wsPromise;
2713
2768
 
2714
2769
  case 2:
@@ -2718,14 +2773,14 @@ var Channel = /*#__PURE__*/function () {
2718
2773
  queryURL += "/".concat(this.id);
2719
2774
  }
2720
2775
 
2721
- _context30.next = 6;
2776
+ _context31.next = 6;
2722
2777
  return this.getClient().post(queryURL + '/query', _objectSpread$5({
2723
2778
  data: this._data,
2724
2779
  state: true
2725
2780
  }, options));
2726
2781
 
2727
2782
  case 6:
2728
- state = _context30.sent;
2783
+ state = _context31.sent;
2729
2784
 
2730
2785
  // update the channel id if it was missing
2731
2786
  if (!this.id) {
@@ -2755,17 +2810,17 @@ var Channel = /*#__PURE__*/function () {
2755
2810
 
2756
2811
  this._initializeState(state);
2757
2812
 
2758
- return _context30.abrupt("return", state);
2813
+ return _context31.abrupt("return", state);
2759
2814
 
2760
2815
  case 11:
2761
2816
  case "end":
2762
- return _context30.stop();
2817
+ return _context31.stop();
2763
2818
  }
2764
2819
  }
2765
- }, _callee30, this);
2820
+ }, _callee31, this);
2766
2821
  }));
2767
2822
 
2768
- function query(_x29) {
2823
+ function query(_x30) {
2769
2824
  return _query.apply(this, arguments);
2770
2825
  }
2771
2826
 
@@ -2782,31 +2837,31 @@ var Channel = /*#__PURE__*/function () {
2782
2837
  }, {
2783
2838
  key: "banUser",
2784
2839
  value: function () {
2785
- var _banUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee31(targetUserID, options) {
2786
- return _regeneratorRuntime.wrap(function _callee31$(_context31) {
2840
+ var _banUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee32(targetUserID, options) {
2841
+ return _regeneratorRuntime.wrap(function _callee32$(_context32) {
2787
2842
  while (1) {
2788
- switch (_context31.prev = _context31.next) {
2843
+ switch (_context32.prev = _context32.next) {
2789
2844
  case 0:
2790
2845
  this._checkInitialized();
2791
2846
 
2792
- _context31.next = 3;
2847
+ _context32.next = 3;
2793
2848
  return this.getClient().banUser(targetUserID, _objectSpread$5(_objectSpread$5({}, options), {}, {
2794
2849
  type: this.type,
2795
2850
  id: this.id
2796
2851
  }));
2797
2852
 
2798
2853
  case 3:
2799
- return _context31.abrupt("return", _context31.sent);
2854
+ return _context32.abrupt("return", _context32.sent);
2800
2855
 
2801
2856
  case 4:
2802
2857
  case "end":
2803
- return _context31.stop();
2858
+ return _context32.stop();
2804
2859
  }
2805
2860
  }
2806
- }, _callee31, this);
2861
+ }, _callee32, this);
2807
2862
  }));
2808
2863
 
2809
- function banUser(_x30, _x31) {
2864
+ function banUser(_x31, _x32) {
2810
2865
  return _banUser.apply(this, arguments);
2811
2866
  }
2812
2867
 
@@ -2824,34 +2879,34 @@ var Channel = /*#__PURE__*/function () {
2824
2879
  }, {
2825
2880
  key: "hide",
2826
2881
  value: function () {
2827
- var _hide = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee32() {
2882
+ var _hide = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee33() {
2828
2883
  var userId,
2829
2884
  clearHistory,
2830
- _args32 = arguments;
2831
- return _regeneratorRuntime.wrap(function _callee32$(_context32) {
2885
+ _args33 = arguments;
2886
+ return _regeneratorRuntime.wrap(function _callee33$(_context33) {
2832
2887
  while (1) {
2833
- switch (_context32.prev = _context32.next) {
2888
+ switch (_context33.prev = _context33.next) {
2834
2889
  case 0:
2835
- userId = _args32.length > 0 && _args32[0] !== undefined ? _args32[0] : null;
2836
- clearHistory = _args32.length > 1 && _args32[1] !== undefined ? _args32[1] : false;
2890
+ userId = _args33.length > 0 && _args33[0] !== undefined ? _args33[0] : null;
2891
+ clearHistory = _args33.length > 1 && _args33[1] !== undefined ? _args33[1] : false;
2837
2892
 
2838
2893
  this._checkInitialized();
2839
2894
 
2840
- _context32.next = 5;
2895
+ _context33.next = 5;
2841
2896
  return this.getClient().post("".concat(this._channelURL(), "/hide"), {
2842
2897
  user_id: userId,
2843
2898
  clear_history: clearHistory
2844
2899
  });
2845
2900
 
2846
2901
  case 5:
2847
- return _context32.abrupt("return", _context32.sent);
2902
+ return _context33.abrupt("return", _context33.sent);
2848
2903
 
2849
2904
  case 6:
2850
2905
  case "end":
2851
- return _context32.stop();
2906
+ return _context33.stop();
2852
2907
  }
2853
2908
  }
2854
- }, _callee32, this);
2909
+ }, _callee33, this);
2855
2910
  }));
2856
2911
 
2857
2912
  function hide() {
@@ -2870,31 +2925,31 @@ var Channel = /*#__PURE__*/function () {
2870
2925
  }, {
2871
2926
  key: "show",
2872
2927
  value: function () {
2873
- var _show = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee33() {
2928
+ var _show = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee34() {
2874
2929
  var userId,
2875
- _args33 = arguments;
2876
- return _regeneratorRuntime.wrap(function _callee33$(_context33) {
2930
+ _args34 = arguments;
2931
+ return _regeneratorRuntime.wrap(function _callee34$(_context34) {
2877
2932
  while (1) {
2878
- switch (_context33.prev = _context33.next) {
2933
+ switch (_context34.prev = _context34.next) {
2879
2934
  case 0:
2880
- userId = _args33.length > 0 && _args33[0] !== undefined ? _args33[0] : null;
2935
+ userId = _args34.length > 0 && _args34[0] !== undefined ? _args34[0] : null;
2881
2936
 
2882
2937
  this._checkInitialized();
2883
2938
 
2884
- _context33.next = 4;
2939
+ _context34.next = 4;
2885
2940
  return this.getClient().post("".concat(this._channelURL(), "/show"), {
2886
2941
  user_id: userId
2887
2942
  });
2888
2943
 
2889
2944
  case 4:
2890
- return _context33.abrupt("return", _context33.sent);
2945
+ return _context34.abrupt("return", _context34.sent);
2891
2946
 
2892
2947
  case 5:
2893
2948
  case "end":
2894
- return _context33.stop();
2949
+ return _context34.stop();
2895
2950
  }
2896
2951
  }
2897
- }, _callee33, this);
2952
+ }, _callee34, this);
2898
2953
  }));
2899
2954
 
2900
2955
  function show() {
@@ -2913,31 +2968,31 @@ var Channel = /*#__PURE__*/function () {
2913
2968
  }, {
2914
2969
  key: "unbanUser",
2915
2970
  value: function () {
2916
- var _unbanUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee34(targetUserID) {
2917
- return _regeneratorRuntime.wrap(function _callee34$(_context34) {
2971
+ var _unbanUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee35(targetUserID) {
2972
+ return _regeneratorRuntime.wrap(function _callee35$(_context35) {
2918
2973
  while (1) {
2919
- switch (_context34.prev = _context34.next) {
2974
+ switch (_context35.prev = _context35.next) {
2920
2975
  case 0:
2921
2976
  this._checkInitialized();
2922
2977
 
2923
- _context34.next = 3;
2978
+ _context35.next = 3;
2924
2979
  return this.getClient().unbanUser(targetUserID, {
2925
2980
  type: this.type,
2926
2981
  id: this.id
2927
2982
  });
2928
2983
 
2929
2984
  case 3:
2930
- return _context34.abrupt("return", _context34.sent);
2985
+ return _context35.abrupt("return", _context35.sent);
2931
2986
 
2932
2987
  case 4:
2933
2988
  case "end":
2934
- return _context34.stop();
2989
+ return _context35.stop();
2935
2990
  }
2936
2991
  }
2937
- }, _callee34, this);
2992
+ }, _callee35, this);
2938
2993
  }));
2939
2994
 
2940
- function unbanUser(_x32) {
2995
+ function unbanUser(_x33) {
2941
2996
  return _unbanUser.apply(this, arguments);
2942
2997
  }
2943
2998
 
@@ -2954,31 +3009,31 @@ var Channel = /*#__PURE__*/function () {
2954
3009
  }, {
2955
3010
  key: "shadowBan",
2956
3011
  value: function () {
2957
- var _shadowBan = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee35(targetUserID, options) {
2958
- return _regeneratorRuntime.wrap(function _callee35$(_context35) {
3012
+ var _shadowBan = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee36(targetUserID, options) {
3013
+ return _regeneratorRuntime.wrap(function _callee36$(_context36) {
2959
3014
  while (1) {
2960
- switch (_context35.prev = _context35.next) {
3015
+ switch (_context36.prev = _context36.next) {
2961
3016
  case 0:
2962
3017
  this._checkInitialized();
2963
3018
 
2964
- _context35.next = 3;
3019
+ _context36.next = 3;
2965
3020
  return this.getClient().shadowBan(targetUserID, _objectSpread$5(_objectSpread$5({}, options), {}, {
2966
3021
  type: this.type,
2967
3022
  id: this.id
2968
3023
  }));
2969
3024
 
2970
3025
  case 3:
2971
- return _context35.abrupt("return", _context35.sent);
3026
+ return _context36.abrupt("return", _context36.sent);
2972
3027
 
2973
3028
  case 4:
2974
3029
  case "end":
2975
- return _context35.stop();
3030
+ return _context36.stop();
2976
3031
  }
2977
3032
  }
2978
- }, _callee35, this);
3033
+ }, _callee36, this);
2979
3034
  }));
2980
3035
 
2981
- function shadowBan(_x33, _x34) {
3036
+ function shadowBan(_x34, _x35) {
2982
3037
  return _shadowBan.apply(this, arguments);
2983
3038
  }
2984
3039
 
@@ -2994,31 +3049,31 @@ var Channel = /*#__PURE__*/function () {
2994
3049
  }, {
2995
3050
  key: "removeShadowBan",
2996
3051
  value: function () {
2997
- var _removeShadowBan = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee36(targetUserID) {
2998
- return _regeneratorRuntime.wrap(function _callee36$(_context36) {
3052
+ var _removeShadowBan = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee37(targetUserID) {
3053
+ return _regeneratorRuntime.wrap(function _callee37$(_context37) {
2999
3054
  while (1) {
3000
- switch (_context36.prev = _context36.next) {
3055
+ switch (_context37.prev = _context37.next) {
3001
3056
  case 0:
3002
3057
  this._checkInitialized();
3003
3058
 
3004
- _context36.next = 3;
3059
+ _context37.next = 3;
3005
3060
  return this.getClient().removeShadowBan(targetUserID, {
3006
3061
  type: this.type,
3007
3062
  id: this.id
3008
3063
  });
3009
3064
 
3010
3065
  case 3:
3011
- return _context36.abrupt("return", _context36.sent);
3066
+ return _context37.abrupt("return", _context37.sent);
3012
3067
 
3013
3068
  case 4:
3014
3069
  case "end":
3015
- return _context36.stop();
3070
+ return _context37.stop();
3016
3071
  }
3017
3072
  }
3018
- }, _callee36, this);
3073
+ }, _callee37, this);
3019
3074
  }));
3020
3075
 
3021
- function removeShadowBan(_x35) {
3076
+ function removeShadowBan(_x36) {
3022
3077
  return _removeShadowBan.apply(this, arguments);
3023
3078
  }
3024
3079
 
@@ -3220,7 +3275,16 @@ var Channel = /*#__PURE__*/function () {
3220
3275
 
3221
3276
  case 'channel.truncated':
3222
3277
  channelState.clearMessages();
3223
- channelState.unreadCount = 0;
3278
+ channelState.unreadCount = 0; // system messages don't increment unread counts
3279
+
3280
+ if (event.message) {
3281
+ channelState.addMessageSorted(event.message);
3282
+
3283
+ if (event.message.pinned) {
3284
+ channelState.addPinnedMessage(event.message);
3285
+ }
3286
+ }
3287
+
3224
3288
  break;
3225
3289
 
3226
3290
  case 'member.added':
@@ -3240,7 +3304,12 @@ var Channel = /*#__PURE__*/function () {
3240
3304
 
3241
3305
  case 'channel.updated':
3242
3306
  if (event.channel) {
3243
- channel.data = event.channel;
3307
+ var _event$channel$hidden, _event$channel, _channel$data, _event$channel$own_ca, _event$channel2, _channel$data2;
3308
+
3309
+ channel.data = _objectSpread$5(_objectSpread$5({}, event.channel), {}, {
3310
+ hidden: (_event$channel$hidden = (_event$channel = event.channel) === null || _event$channel === void 0 ? void 0 : _event$channel.hidden) !== null && _event$channel$hidden !== void 0 ? _event$channel$hidden : (_channel$data = channel.data) === null || _channel$data === void 0 ? void 0 : _channel$data.hidden,
3311
+ own_capabilities: (_event$channel$own_ca = (_event$channel2 = event.channel) === null || _event$channel2 === void 0 ? void 0 : _event$channel2.own_capabilities) !== null && _event$channel$own_ca !== void 0 ? _event$channel$own_ca : (_channel$data2 = channel.data) === null || _channel$data2 === void 0 ? void 0 : _channel$data2.own_capabilities
3312
+ });
3244
3313
  }
3245
3314
 
3246
3315
  break;
@@ -3427,7 +3496,7 @@ var Channel = /*#__PURE__*/function () {
3427
3496
  return Channel;
3428
3497
  }();
3429
3498
 
3430
- function _createForOfIteratorHelper$1(o, allowArrayLike) { var it; if (typeof Symbol === "undefined" || o[Symbol.iterator] == null) { if (Array.isArray(o) || (it = _unsupportedIterableToArray$1(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = o[Symbol.iterator](); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }
3499
+ function _createForOfIteratorHelper$1(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray$1(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }
3431
3500
 
3432
3501
  function _unsupportedIterableToArray$1(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray$1(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$1(o, minLen); }
3433
3502
 
@@ -3502,7 +3571,7 @@ var ClientState = /*#__PURE__*/function () {
3502
3571
  return ClientState;
3503
3572
  }();
3504
3573
 
3505
- function ownKeys$4(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
3574
+ function ownKeys$4(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
3506
3575
 
3507
3576
  function _objectSpread$4(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys$4(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys$4(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
3508
3577
  var InsightMetrics = function InsightMetrics() {
@@ -3616,7 +3685,7 @@ function buildWsSuccessAfterFailureInsight(connection) {
3616
3685
  return buildWsBaseInsight(connection);
3617
3686
  }
3618
3687
 
3619
- function ownKeys$3(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
3688
+ function ownKeys$3(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
3620
3689
 
3621
3690
  function _objectSpread$3(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys$3(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys$3(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
3622
3691
 
@@ -4534,7 +4603,7 @@ var StableWSConnection = /*#__PURE__*/function () {
4534
4603
  return StableWSConnection;
4535
4604
  }();
4536
4605
 
4537
- function ownKeys$2(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
4606
+ function ownKeys$2(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
4538
4607
 
4539
4608
  function _objectSpread$2(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys$2(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys$2(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
4540
4609
 
@@ -4949,7 +5018,7 @@ function isWSFailure(err) {
4949
5018
  }
4950
5019
  }
4951
5020
 
4952
- function ownKeys$1(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
5021
+ function ownKeys$1(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
4953
5022
 
4954
5023
  function _objectSpread$1(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys$1(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys$1(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
4955
5024
  var ConnectionState;
@@ -5226,7 +5295,7 @@ var WSConnectionFallback = /*#__PURE__*/function () {
5226
5295
  })));
5227
5296
 
5228
5297
  _defineProperty(this, "isHealthy", function () {
5229
- return _this.connectionID && _this.state === ConnectionState.Connected;
5298
+ return !!_this.connectionID && _this.state === ConnectionState.Connected;
5230
5299
  });
5231
5300
 
5232
5301
  _defineProperty(this, "disconnect", /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee4() {
@@ -5325,13 +5394,15 @@ var WSConnectionFallback = /*#__PURE__*/function () {
5325
5394
  return WSConnectionFallback;
5326
5395
  }();
5327
5396
 
5328
- function _createForOfIteratorHelper(o, allowArrayLike) { var it; if (typeof Symbol === "undefined" || o[Symbol.iterator] == null) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = o[Symbol.iterator](); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }
5397
+ var _excluded = ["created_at", "updated_at", "last_active", "online"];
5398
+
5399
+ function _createForOfIteratorHelper(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }
5329
5400
 
5330
5401
  function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
5331
5402
 
5332
5403
  function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
5333
5404
 
5334
- function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
5405
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
5335
5406
 
5336
5407
  function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
5337
5408
 
@@ -6636,7 +6707,7 @@ var StreamChat = /*#__PURE__*/function () {
6636
6707
  case 11:
6637
6708
  this.anonymous = false; // eslint-disable-next-line @typescript-eslint/no-unused-vars
6638
6709
 
6639
- _response$user = response.user, _response$user.created_at, _response$user.updated_at, _response$user.last_active, _response$user.online, guestUser = _objectWithoutProperties(_response$user, ["created_at", "updated_at", "last_active", "online"]);
6710
+ _response$user = response.user, _response$user.created_at, _response$user.updated_at, _response$user.last_active, _response$user.online, guestUser = _objectWithoutProperties(_response$user, _excluded);
6640
6711
  _context14.next = 15;
6641
6712
  return this.connectUser(guestUser, response.access_token);
6642
6713
 
@@ -8464,6 +8535,101 @@ var StreamChat = /*#__PURE__*/function () {
8464
8535
 
8465
8536
  return unflagUser;
8466
8537
  }()
8538
+ /**
8539
+ * _queryFlagReports - Query flag reports.
8540
+ *
8541
+ * Note: Do not use this.
8542
+ * It is present for internal usage only.
8543
+ * This function can, and will, break and/or be removed at any point in time.
8544
+ *
8545
+ * @param {FlagReportsFilters} filterConditions MongoDB style filter conditions
8546
+ * @param {FlagReportsPaginationOptions} options Option object, {limit: 10, offset:0}
8547
+ *
8548
+ * @return {Promise<FlagReportsResponse<ChannelType, CommandType, UserType>>} Flag Reports Response
8549
+ */
8550
+
8551
+ }, {
8552
+ key: "_queryFlagReports",
8553
+ value: function () {
8554
+ var _queryFlagReports2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee42() {
8555
+ var filterConditions,
8556
+ options,
8557
+ _args42 = arguments;
8558
+ return _regeneratorRuntime.wrap(function _callee42$(_context42) {
8559
+ while (1) {
8560
+ switch (_context42.prev = _context42.next) {
8561
+ case 0:
8562
+ filterConditions = _args42.length > 0 && _args42[0] !== undefined ? _args42[0] : {};
8563
+ options = _args42.length > 1 && _args42[1] !== undefined ? _args42[1] : {};
8564
+ _context42.next = 4;
8565
+ return this.post(this.baseURL + '/moderation/reports', _objectSpread({
8566
+ filter_conditions: filterConditions
8567
+ }, options));
8568
+
8569
+ case 4:
8570
+ return _context42.abrupt("return", _context42.sent);
8571
+
8572
+ case 5:
8573
+ case "end":
8574
+ return _context42.stop();
8575
+ }
8576
+ }
8577
+ }, _callee42, this);
8578
+ }));
8579
+
8580
+ function _queryFlagReports() {
8581
+ return _queryFlagReports2.apply(this, arguments);
8582
+ }
8583
+
8584
+ return _queryFlagReports;
8585
+ }()
8586
+ /**
8587
+ * _reviewFlagReport - review flag report
8588
+ *
8589
+ * Note: Do not use this.
8590
+ * It is present for internal usage only.
8591
+ * This function can, and will, break and/or be removed at any point in time.
8592
+ *
8593
+ * @param {string} [id] flag report to review
8594
+ * @param {string} [reviewResult] flag report review result
8595
+ * @param {string} [options.user_id] currentUserID, only used with serverside auth
8596
+ * @param {string} [options.review_details] custom information about review result
8597
+ * @returns {Promise<ReviewFlagReportResponse>>}
8598
+ */
8599
+
8600
+ }, {
8601
+ key: "_reviewFlagReport",
8602
+ value: function () {
8603
+ var _reviewFlagReport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee43(id, reviewResult) {
8604
+ var options,
8605
+ _args43 = arguments;
8606
+ return _regeneratorRuntime.wrap(function _callee43$(_context43) {
8607
+ while (1) {
8608
+ switch (_context43.prev = _context43.next) {
8609
+ case 0:
8610
+ options = _args43.length > 2 && _args43[2] !== undefined ? _args43[2] : {};
8611
+ _context43.next = 3;
8612
+ return this.patch(this.baseURL + "/moderation/reports/".concat(id), _objectSpread({
8613
+ review_result: reviewResult
8614
+ }, options));
8615
+
8616
+ case 3:
8617
+ return _context43.abrupt("return", _context43.sent);
8618
+
8619
+ case 4:
8620
+ case "end":
8621
+ return _context43.stop();
8622
+ }
8623
+ }
8624
+ }, _callee43, this);
8625
+ }));
8626
+
8627
+ function _reviewFlagReport(_x54, _x55) {
8628
+ return _reviewFlagReport2.apply(this, arguments);
8629
+ }
8630
+
8631
+ return _reviewFlagReport;
8632
+ }()
8467
8633
  /**
8468
8634
  * @deprecated use markChannelsRead instead
8469
8635
  *
@@ -8485,23 +8651,23 @@ var StreamChat = /*#__PURE__*/function () {
8485
8651
  * @return {Promise<APIResponse>}
8486
8652
  */
8487
8653
  function () {
8488
- var _markChannelsRead = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee42() {
8654
+ var _markChannelsRead = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee44() {
8489
8655
  var data,
8490
- _args42 = arguments;
8491
- return _regeneratorRuntime.wrap(function _callee42$(_context42) {
8656
+ _args44 = arguments;
8657
+ return _regeneratorRuntime.wrap(function _callee44$(_context44) {
8492
8658
  while (1) {
8493
- switch (_context42.prev = _context42.next) {
8659
+ switch (_context44.prev = _context44.next) {
8494
8660
  case 0:
8495
- data = _args42.length > 0 && _args42[0] !== undefined ? _args42[0] : {};
8496
- _context42.next = 3;
8661
+ data = _args44.length > 0 && _args44[0] !== undefined ? _args44[0] : {};
8662
+ _context44.next = 3;
8497
8663
  return this.post(this.baseURL + '/channels/read', _objectSpread({}, data));
8498
8664
 
8499
8665
  case 3:
8500
8666
  case "end":
8501
- return _context42.stop();
8667
+ return _context44.stop();
8502
8668
  }
8503
8669
  }
8504
- }, _callee42, this);
8670
+ }, _callee44, this);
8505
8671
  }));
8506
8672
 
8507
8673
  function markChannelsRead() {
@@ -8576,28 +8742,28 @@ var StreamChat = /*#__PURE__*/function () {
8576
8742
  }, {
8577
8743
  key: "translateMessage",
8578
8744
  value: function () {
8579
- var _translateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee43(messageId, language) {
8580
- return _regeneratorRuntime.wrap(function _callee43$(_context43) {
8745
+ var _translateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee45(messageId, language) {
8746
+ return _regeneratorRuntime.wrap(function _callee45$(_context45) {
8581
8747
  while (1) {
8582
- switch (_context43.prev = _context43.next) {
8748
+ switch (_context45.prev = _context45.next) {
8583
8749
  case 0:
8584
- _context43.next = 2;
8750
+ _context45.next = 2;
8585
8751
  return this.post(this.baseURL + "/messages/".concat(messageId, "/translate"), {
8586
8752
  language: language
8587
8753
  });
8588
8754
 
8589
8755
  case 2:
8590
- return _context43.abrupt("return", _context43.sent);
8756
+ return _context45.abrupt("return", _context45.sent);
8591
8757
 
8592
8758
  case 3:
8593
8759
  case "end":
8594
- return _context43.stop();
8760
+ return _context45.stop();
8595
8761
  }
8596
8762
  }
8597
- }, _callee43, this);
8763
+ }, _callee45, this);
8598
8764
  }));
8599
8765
 
8600
- function translateMessage(_x54, _x55) {
8766
+ function translateMessage(_x56, _x57) {
8601
8767
  return _translateMessage.apply(this, arguments);
8602
8768
  }
8603
8769
 
@@ -8611,7 +8777,7 @@ var StreamChat = /*#__PURE__*/function () {
8611
8777
  }, {
8612
8778
  key: "_normalizeExpiration",
8613
8779
  value: function _normalizeExpiration(timeoutOrExpirationDate) {
8614
- var pinExpires;
8780
+ var pinExpires = null;
8615
8781
 
8616
8782
  if (typeof timeoutOrExpirationDate === 'number') {
8617
8783
  var now = new Date();
@@ -8652,20 +8818,22 @@ var StreamChat = /*#__PURE__*/function () {
8652
8818
  * pinMessage - pins the message
8653
8819
  * @param {string | { id: string }} messageOrMessageId message object or message id
8654
8820
  * @param {undefined|null|number|string|Date} timeoutOrExpirationDate expiration date or timeout. Use number type to set timeout in seconds, string or Date to set exact expiration date
8655
- * @param {string | { id: string }} [userId]
8821
+ * @param {undefined|string | { id: string }} [pinnedBy] who will appear as a user who pinned a message. Only for server-side use. Provide `undefined` when pinning message client-side
8822
+ * @param {undefined|number|string|Date} pinnedAt date when message should be pinned. It affects the order of pinned messages. Use negative number to set relative time in the past, string or Date to set exact date of pin
8656
8823
  */
8657
8824
 
8658
8825
  }, {
8659
8826
  key: "pinMessage",
8660
- value: function pinMessage(messageOrMessageId, timeoutOrExpirationDate, userId) {
8827
+ value: function pinMessage(messageOrMessageId, timeoutOrExpirationDate, pinnedBy, pinnedAt) {
8661
8828
  var messageId = this._validateAndGetMessageId(messageOrMessageId, 'Please specify the message id when calling unpinMessage');
8662
8829
 
8663
8830
  return this.partialUpdateMessage(messageId, {
8664
8831
  set: {
8665
8832
  pinned: true,
8666
- pin_expires: this._normalizeExpiration(timeoutOrExpirationDate)
8833
+ pin_expires: this._normalizeExpiration(timeoutOrExpirationDate),
8834
+ pinned_at: this._normalizeExpiration(pinnedAt)
8667
8835
  }
8668
- }, userId);
8836
+ }, pinnedBy);
8669
8837
  }
8670
8838
  /**
8671
8839
  * unpinMessage - unpins the message that was previously pinned
@@ -8697,14 +8865,14 @@ var StreamChat = /*#__PURE__*/function () {
8697
8865
  }, {
8698
8866
  key: "updateMessage",
8699
8867
  value: function () {
8700
- var _updateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee44(message, userId, options) {
8868
+ var _updateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee46(message, userId, options) {
8701
8869
  var clonedMessage, reservedMessageFields;
8702
- return _regeneratorRuntime.wrap(function _callee44$(_context44) {
8870
+ return _regeneratorRuntime.wrap(function _callee46$(_context46) {
8703
8871
  while (1) {
8704
- switch (_context44.prev = _context44.next) {
8872
+ switch (_context46.prev = _context46.next) {
8705
8873
  case 0:
8706
8874
  if (message.id) {
8707
- _context44.next = 2;
8875
+ _context46.next = 2;
8708
8876
  break;
8709
8877
  }
8710
8878
 
@@ -8741,23 +8909,23 @@ var StreamChat = /*#__PURE__*/function () {
8741
8909
  });
8742
8910
  }
8743
8911
 
8744
- _context44.next = 10;
8912
+ _context46.next = 10;
8745
8913
  return this.post(this.baseURL + "/messages/".concat(message.id), _objectSpread({
8746
8914
  message: clonedMessage
8747
8915
  }, options));
8748
8916
 
8749
8917
  case 10:
8750
- return _context44.abrupt("return", _context44.sent);
8918
+ return _context46.abrupt("return", _context46.sent);
8751
8919
 
8752
8920
  case 11:
8753
8921
  case "end":
8754
- return _context44.stop();
8922
+ return _context46.stop();
8755
8923
  }
8756
8924
  }
8757
- }, _callee44, this);
8925
+ }, _callee46, this);
8758
8926
  }));
8759
8927
 
8760
- function updateMessage(_x56, _x57, _x58) {
8928
+ function updateMessage(_x58, _x59, _x60) {
8761
8929
  return _updateMessage.apply(this, arguments);
8762
8930
  }
8763
8931
 
@@ -8780,14 +8948,14 @@ var StreamChat = /*#__PURE__*/function () {
8780
8948
  }, {
8781
8949
  key: "partialUpdateMessage",
8782
8950
  value: function () {
8783
- var _partialUpdateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee45(id, partialMessageObject, userId, options) {
8951
+ var _partialUpdateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee47(id, partialMessageObject, userId, options) {
8784
8952
  var user;
8785
- return _regeneratorRuntime.wrap(function _callee45$(_context45) {
8953
+ return _regeneratorRuntime.wrap(function _callee47$(_context47) {
8786
8954
  while (1) {
8787
- switch (_context45.prev = _context45.next) {
8955
+ switch (_context47.prev = _context47.next) {
8788
8956
  case 0:
8789
8957
  if (id) {
8790
- _context45.next = 2;
8958
+ _context47.next = 2;
8791
8959
  break;
8792
8960
  }
8793
8961
 
@@ -8802,23 +8970,23 @@ var StreamChat = /*#__PURE__*/function () {
8802
8970
  };
8803
8971
  }
8804
8972
 
8805
- _context45.next = 6;
8973
+ _context47.next = 6;
8806
8974
  return this.put(this.baseURL + "/messages/".concat(id), _objectSpread(_objectSpread(_objectSpread({}, partialMessageObject), options), {}, {
8807
8975
  user: user
8808
8976
  }));
8809
8977
 
8810
8978
  case 6:
8811
- return _context45.abrupt("return", _context45.sent);
8979
+ return _context47.abrupt("return", _context47.sent);
8812
8980
 
8813
8981
  case 7:
8814
8982
  case "end":
8815
- return _context45.stop();
8983
+ return _context47.stop();
8816
8984
  }
8817
8985
  }
8818
- }, _callee45, this);
8986
+ }, _callee47, this);
8819
8987
  }));
8820
8988
 
8821
- function partialUpdateMessage(_x59, _x60, _x61, _x62) {
8989
+ function partialUpdateMessage(_x61, _x62, _x63, _x64) {
8822
8990
  return _partialUpdateMessage.apply(this, arguments);
8823
8991
  }
8824
8992
 
@@ -8827,11 +8995,11 @@ var StreamChat = /*#__PURE__*/function () {
8827
8995
  }, {
8828
8996
  key: "deleteMessage",
8829
8997
  value: function () {
8830
- var _deleteMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee46(messageID, hardDelete) {
8998
+ var _deleteMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee48(messageID, hardDelete) {
8831
8999
  var params;
8832
- return _regeneratorRuntime.wrap(function _callee46$(_context46) {
9000
+ return _regeneratorRuntime.wrap(function _callee48$(_context48) {
8833
9001
  while (1) {
8834
- switch (_context46.prev = _context46.next) {
9002
+ switch (_context48.prev = _context48.next) {
8835
9003
  case 0:
8836
9004
  params = {};
8837
9005
 
@@ -8841,21 +9009,21 @@ var StreamChat = /*#__PURE__*/function () {
8841
9009
  };
8842
9010
  }
8843
9011
 
8844
- _context46.next = 4;
9012
+ _context48.next = 4;
8845
9013
  return this.delete(this.baseURL + "/messages/".concat(messageID), params);
8846
9014
 
8847
9015
  case 4:
8848
- return _context46.abrupt("return", _context46.sent);
9016
+ return _context48.abrupt("return", _context48.sent);
8849
9017
 
8850
9018
  case 5:
8851
9019
  case "end":
8852
- return _context46.stop();
9020
+ return _context48.stop();
8853
9021
  }
8854
9022
  }
8855
- }, _callee46, this);
9023
+ }, _callee48, this);
8856
9024
  }));
8857
9025
 
8858
- function deleteMessage(_x63, _x64) {
9026
+ function deleteMessage(_x65, _x66) {
8859
9027
  return _deleteMessage.apply(this, arguments);
8860
9028
  }
8861
9029
 
@@ -8864,26 +9032,26 @@ var StreamChat = /*#__PURE__*/function () {
8864
9032
  }, {
8865
9033
  key: "getMessage",
8866
9034
  value: function () {
8867
- var _getMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee47(messageID) {
8868
- return _regeneratorRuntime.wrap(function _callee47$(_context47) {
9035
+ var _getMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee49(messageID) {
9036
+ return _regeneratorRuntime.wrap(function _callee49$(_context49) {
8869
9037
  while (1) {
8870
- switch (_context47.prev = _context47.next) {
9038
+ switch (_context49.prev = _context49.next) {
8871
9039
  case 0:
8872
- _context47.next = 2;
9040
+ _context49.next = 2;
8873
9041
  return this.get(this.baseURL + "/messages/".concat(messageID));
8874
9042
 
8875
9043
  case 2:
8876
- return _context47.abrupt("return", _context47.sent);
9044
+ return _context49.abrupt("return", _context49.sent);
8877
9045
 
8878
9046
  case 3:
8879
9047
  case "end":
8880
- return _context47.stop();
9048
+ return _context49.stop();
8881
9049
  }
8882
9050
  }
8883
- }, _callee47, this);
9051
+ }, _callee49, this);
8884
9052
  }));
8885
9053
 
8886
- function getMessage(_x65) {
9054
+ function getMessage(_x67) {
8887
9055
  return _getMessage.apply(this, arguments);
8888
9056
  }
8889
9057
 
@@ -8892,7 +9060,7 @@ var StreamChat = /*#__PURE__*/function () {
8892
9060
  }, {
8893
9061
  key: "getUserAgent",
8894
9062
  value: function getUserAgent() {
8895
- return this.userAgent || "stream-chat-javascript-client-".concat(this.node ? 'node' : 'browser', "-", "5.0.1");
9063
+ return this.userAgent || "stream-chat-javascript-client-".concat(this.node ? 'node' : 'browser', "-", "5.2.0");
8896
9064
  }
8897
9065
  }, {
8898
9066
  key: "setUserAgent",
@@ -9087,28 +9255,28 @@ var StreamChat = /*#__PURE__*/function () {
9087
9255
  }, {
9088
9256
  key: "sendUserCustomEvent",
9089
9257
  value: function () {
9090
- var _sendUserCustomEvent = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee48(targetUserID, event) {
9091
- return _regeneratorRuntime.wrap(function _callee48$(_context48) {
9258
+ var _sendUserCustomEvent = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee50(targetUserID, event) {
9259
+ return _regeneratorRuntime.wrap(function _callee50$(_context50) {
9092
9260
  while (1) {
9093
- switch (_context48.prev = _context48.next) {
9261
+ switch (_context50.prev = _context50.next) {
9094
9262
  case 0:
9095
- _context48.next = 2;
9263
+ _context50.next = 2;
9096
9264
  return this.post("".concat(this.baseURL, "/users/").concat(targetUserID, "/event"), {
9097
9265
  event: event
9098
9266
  });
9099
9267
 
9100
9268
  case 2:
9101
- return _context48.abrupt("return", _context48.sent);
9269
+ return _context50.abrupt("return", _context50.sent);
9102
9270
 
9103
9271
  case 3:
9104
9272
  case "end":
9105
- return _context48.stop();
9273
+ return _context50.stop();
9106
9274
  }
9107
9275
  }
9108
- }, _callee48, this);
9276
+ }, _callee50, this);
9109
9277
  }));
9110
9278
 
9111
- function sendUserCustomEvent(_x66, _x67) {
9279
+ function sendUserCustomEvent(_x68, _x69) {
9112
9280
  return _sendUserCustomEvent.apply(this, arguments);
9113
9281
  }
9114
9282
 
@@ -9150,6 +9318,11 @@ var StreamChat = /*#__PURE__*/function () {
9150
9318
 
9151
9319
  return this.post("".concat(this.baseURL, "/export_channels"), payload);
9152
9320
  }
9321
+ }, {
9322
+ key: "exportUsers",
9323
+ value: function exportUsers(request) {
9324
+ return this.post("".concat(this.baseURL, "/export/users"), request);
9325
+ }
9153
9326
  }, {
9154
9327
  key: "exportChannel",
9155
9328
  value: function exportChannel(request, options) {
@@ -9171,32 +9344,32 @@ var StreamChat = /*#__PURE__*/function () {
9171
9344
  }, {
9172
9345
  key: "createSegment",
9173
9346
  value: function () {
9174
- var _createSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee49(params) {
9347
+ var _createSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee51(params) {
9175
9348
  var _yield$this$post, segment;
9176
9349
 
9177
- return _regeneratorRuntime.wrap(function _callee49$(_context49) {
9350
+ return _regeneratorRuntime.wrap(function _callee51$(_context51) {
9178
9351
  while (1) {
9179
- switch (_context49.prev = _context49.next) {
9352
+ switch (_context51.prev = _context51.next) {
9180
9353
  case 0:
9181
- _context49.next = 2;
9354
+ _context51.next = 2;
9182
9355
  return this.post(this.baseURL + "/segments", {
9183
9356
  segment: params
9184
9357
  });
9185
9358
 
9186
9359
  case 2:
9187
- _yield$this$post = _context49.sent;
9360
+ _yield$this$post = _context51.sent;
9188
9361
  segment = _yield$this$post.segment;
9189
- return _context49.abrupt("return", segment);
9362
+ return _context51.abrupt("return", segment);
9190
9363
 
9191
9364
  case 5:
9192
9365
  case "end":
9193
- return _context49.stop();
9366
+ return _context51.stop();
9194
9367
  }
9195
9368
  }
9196
- }, _callee49, this);
9369
+ }, _callee51, this);
9197
9370
  }));
9198
9371
 
9199
- function createSegment(_x68) {
9372
+ function createSegment(_x70) {
9200
9373
  return _createSegment.apply(this, arguments);
9201
9374
  }
9202
9375
 
@@ -9213,30 +9386,30 @@ var StreamChat = /*#__PURE__*/function () {
9213
9386
  }, {
9214
9387
  key: "getSegment",
9215
9388
  value: function () {
9216
- var _getSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee50(id) {
9389
+ var _getSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee52(id) {
9217
9390
  var _yield$this$get, segment;
9218
9391
 
9219
- return _regeneratorRuntime.wrap(function _callee50$(_context50) {
9392
+ return _regeneratorRuntime.wrap(function _callee52$(_context52) {
9220
9393
  while (1) {
9221
- switch (_context50.prev = _context50.next) {
9394
+ switch (_context52.prev = _context52.next) {
9222
9395
  case 0:
9223
- _context50.next = 2;
9396
+ _context52.next = 2;
9224
9397
  return this.get(this.baseURL + "/segments/".concat(id));
9225
9398
 
9226
9399
  case 2:
9227
- _yield$this$get = _context50.sent;
9400
+ _yield$this$get = _context52.sent;
9228
9401
  segment = _yield$this$get.segment;
9229
- return _context50.abrupt("return", segment);
9402
+ return _context52.abrupt("return", segment);
9230
9403
 
9231
9404
  case 5:
9232
9405
  case "end":
9233
- return _context50.stop();
9406
+ return _context52.stop();
9234
9407
  }
9235
9408
  }
9236
- }, _callee50, this);
9409
+ }, _callee52, this);
9237
9410
  }));
9238
9411
 
9239
- function getSegment(_x69) {
9412
+ function getSegment(_x71) {
9240
9413
  return _getSegment.apply(this, arguments);
9241
9414
  }
9242
9415
 
@@ -9252,30 +9425,30 @@ var StreamChat = /*#__PURE__*/function () {
9252
9425
  }, {
9253
9426
  key: "listSegments",
9254
9427
  value: function () {
9255
- var _listSegments = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee51(options) {
9428
+ var _listSegments = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee53(options) {
9256
9429
  var _yield$this$get2, segments;
9257
9430
 
9258
- return _regeneratorRuntime.wrap(function _callee51$(_context51) {
9431
+ return _regeneratorRuntime.wrap(function _callee53$(_context53) {
9259
9432
  while (1) {
9260
- switch (_context51.prev = _context51.next) {
9433
+ switch (_context53.prev = _context53.next) {
9261
9434
  case 0:
9262
- _context51.next = 2;
9435
+ _context53.next = 2;
9263
9436
  return this.get(this.baseURL + "/segments", options);
9264
9437
 
9265
9438
  case 2:
9266
- _yield$this$get2 = _context51.sent;
9439
+ _yield$this$get2 = _context53.sent;
9267
9440
  segments = _yield$this$get2.segments;
9268
- return _context51.abrupt("return", segments);
9441
+ return _context53.abrupt("return", segments);
9269
9442
 
9270
9443
  case 5:
9271
9444
  case "end":
9272
- return _context51.stop();
9445
+ return _context53.stop();
9273
9446
  }
9274
9447
  }
9275
- }, _callee51, this);
9448
+ }, _callee53, this);
9276
9449
  }));
9277
9450
 
9278
- function listSegments(_x70) {
9451
+ function listSegments(_x72) {
9279
9452
  return _listSegments.apply(this, arguments);
9280
9453
  }
9281
9454
 
@@ -9293,32 +9466,32 @@ var StreamChat = /*#__PURE__*/function () {
9293
9466
  }, {
9294
9467
  key: "updateSegment",
9295
9468
  value: function () {
9296
- var _updateSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee52(id, params) {
9469
+ var _updateSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee54(id, params) {
9297
9470
  var _yield$this$put, segment;
9298
9471
 
9299
- return _regeneratorRuntime.wrap(function _callee52$(_context52) {
9472
+ return _regeneratorRuntime.wrap(function _callee54$(_context54) {
9300
9473
  while (1) {
9301
- switch (_context52.prev = _context52.next) {
9474
+ switch (_context54.prev = _context54.next) {
9302
9475
  case 0:
9303
- _context52.next = 2;
9476
+ _context54.next = 2;
9304
9477
  return this.put(this.baseURL + "/segments/".concat(id), {
9305
9478
  segment: params
9306
9479
  });
9307
9480
 
9308
9481
  case 2:
9309
- _yield$this$put = _context52.sent;
9482
+ _yield$this$put = _context54.sent;
9310
9483
  segment = _yield$this$put.segment;
9311
- return _context52.abrupt("return", segment);
9484
+ return _context54.abrupt("return", segment);
9312
9485
 
9313
9486
  case 5:
9314
9487
  case "end":
9315
- return _context52.stop();
9488
+ return _context54.stop();
9316
9489
  }
9317
9490
  }
9318
- }, _callee52, this);
9491
+ }, _callee54, this);
9319
9492
  }));
9320
9493
 
9321
- function updateSegment(_x71, _x72) {
9494
+ function updateSegment(_x73, _x74) {
9322
9495
  return _updateSegment.apply(this, arguments);
9323
9496
  }
9324
9497
 
@@ -9335,22 +9508,22 @@ var StreamChat = /*#__PURE__*/function () {
9335
9508
  }, {
9336
9509
  key: "deleteSegment",
9337
9510
  value: function () {
9338
- var _deleteSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee53(id) {
9339
- return _regeneratorRuntime.wrap(function _callee53$(_context53) {
9511
+ var _deleteSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee55(id) {
9512
+ return _regeneratorRuntime.wrap(function _callee55$(_context55) {
9340
9513
  while (1) {
9341
- switch (_context53.prev = _context53.next) {
9514
+ switch (_context55.prev = _context55.next) {
9342
9515
  case 0:
9343
- return _context53.abrupt("return", this.delete(this.baseURL + "/segments/".concat(id)));
9516
+ return _context55.abrupt("return", this.delete(this.baseURL + "/segments/".concat(id)));
9344
9517
 
9345
9518
  case 1:
9346
9519
  case "end":
9347
- return _context53.stop();
9520
+ return _context55.stop();
9348
9521
  }
9349
9522
  }
9350
- }, _callee53, this);
9523
+ }, _callee55, this);
9351
9524
  }));
9352
9525
 
9353
- function deleteSegment(_x73) {
9526
+ function deleteSegment(_x75) {
9354
9527
  return _deleteSegment.apply(this, arguments);
9355
9528
  }
9356
9529
 
@@ -9367,32 +9540,32 @@ var StreamChat = /*#__PURE__*/function () {
9367
9540
  }, {
9368
9541
  key: "createCampaign",
9369
9542
  value: function () {
9370
- var _createCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee54(params) {
9543
+ var _createCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee56(params) {
9371
9544
  var _yield$this$post2, campaign;
9372
9545
 
9373
- return _regeneratorRuntime.wrap(function _callee54$(_context54) {
9546
+ return _regeneratorRuntime.wrap(function _callee56$(_context56) {
9374
9547
  while (1) {
9375
- switch (_context54.prev = _context54.next) {
9548
+ switch (_context56.prev = _context56.next) {
9376
9549
  case 0:
9377
- _context54.next = 2;
9550
+ _context56.next = 2;
9378
9551
  return this.post(this.baseURL + "/campaigns", {
9379
9552
  campaign: params
9380
9553
  });
9381
9554
 
9382
9555
  case 2:
9383
- _yield$this$post2 = _context54.sent;
9556
+ _yield$this$post2 = _context56.sent;
9384
9557
  campaign = _yield$this$post2.campaign;
9385
- return _context54.abrupt("return", campaign);
9558
+ return _context56.abrupt("return", campaign);
9386
9559
 
9387
9560
  case 5:
9388
9561
  case "end":
9389
- return _context54.stop();
9562
+ return _context56.stop();
9390
9563
  }
9391
9564
  }
9392
- }, _callee54, this);
9565
+ }, _callee56, this);
9393
9566
  }));
9394
9567
 
9395
- function createCampaign(_x74) {
9568
+ function createCampaign(_x76) {
9396
9569
  return _createCampaign.apply(this, arguments);
9397
9570
  }
9398
9571
 
@@ -9409,30 +9582,30 @@ var StreamChat = /*#__PURE__*/function () {
9409
9582
  }, {
9410
9583
  key: "getCampaign",
9411
9584
  value: function () {
9412
- var _getCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee55(id) {
9585
+ var _getCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee57(id) {
9413
9586
  var _yield$this$get3, campaign;
9414
9587
 
9415
- return _regeneratorRuntime.wrap(function _callee55$(_context55) {
9588
+ return _regeneratorRuntime.wrap(function _callee57$(_context57) {
9416
9589
  while (1) {
9417
- switch (_context55.prev = _context55.next) {
9590
+ switch (_context57.prev = _context57.next) {
9418
9591
  case 0:
9419
- _context55.next = 2;
9592
+ _context57.next = 2;
9420
9593
  return this.get(this.baseURL + "/campaigns/".concat(id));
9421
9594
 
9422
9595
  case 2:
9423
- _yield$this$get3 = _context55.sent;
9596
+ _yield$this$get3 = _context57.sent;
9424
9597
  campaign = _yield$this$get3.campaign;
9425
- return _context55.abrupt("return", campaign);
9598
+ return _context57.abrupt("return", campaign);
9426
9599
 
9427
9600
  case 5:
9428
9601
  case "end":
9429
- return _context55.stop();
9602
+ return _context57.stop();
9430
9603
  }
9431
9604
  }
9432
- }, _callee55, this);
9605
+ }, _callee57, this);
9433
9606
  }));
9434
9607
 
9435
- function getCampaign(_x75) {
9608
+ function getCampaign(_x77) {
9436
9609
  return _getCampaign.apply(this, arguments);
9437
9610
  }
9438
9611
 
@@ -9448,30 +9621,30 @@ var StreamChat = /*#__PURE__*/function () {
9448
9621
  }, {
9449
9622
  key: "listCampaigns",
9450
9623
  value: function () {
9451
- var _listCampaigns = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee56(options) {
9624
+ var _listCampaigns = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee58(options) {
9452
9625
  var _yield$this$get4, campaigns;
9453
9626
 
9454
- return _regeneratorRuntime.wrap(function _callee56$(_context56) {
9627
+ return _regeneratorRuntime.wrap(function _callee58$(_context58) {
9455
9628
  while (1) {
9456
- switch (_context56.prev = _context56.next) {
9629
+ switch (_context58.prev = _context58.next) {
9457
9630
  case 0:
9458
- _context56.next = 2;
9631
+ _context58.next = 2;
9459
9632
  return this.get(this.baseURL + "/campaigns", options);
9460
9633
 
9461
9634
  case 2:
9462
- _yield$this$get4 = _context56.sent;
9635
+ _yield$this$get4 = _context58.sent;
9463
9636
  campaigns = _yield$this$get4.campaigns;
9464
- return _context56.abrupt("return", campaigns);
9637
+ return _context58.abrupt("return", campaigns);
9465
9638
 
9466
9639
  case 5:
9467
9640
  case "end":
9468
- return _context56.stop();
9641
+ return _context58.stop();
9469
9642
  }
9470
9643
  }
9471
- }, _callee56, this);
9644
+ }, _callee58, this);
9472
9645
  }));
9473
9646
 
9474
- function listCampaigns(_x76) {
9647
+ function listCampaigns(_x78) {
9475
9648
  return _listCampaigns.apply(this, arguments);
9476
9649
  }
9477
9650
 
@@ -9489,32 +9662,32 @@ var StreamChat = /*#__PURE__*/function () {
9489
9662
  }, {
9490
9663
  key: "updateCampaign",
9491
9664
  value: function () {
9492
- var _updateCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee57(id, params) {
9665
+ var _updateCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee59(id, params) {
9493
9666
  var _yield$this$put2, campaign;
9494
9667
 
9495
- return _regeneratorRuntime.wrap(function _callee57$(_context57) {
9668
+ return _regeneratorRuntime.wrap(function _callee59$(_context59) {
9496
9669
  while (1) {
9497
- switch (_context57.prev = _context57.next) {
9670
+ switch (_context59.prev = _context59.next) {
9498
9671
  case 0:
9499
- _context57.next = 2;
9672
+ _context59.next = 2;
9500
9673
  return this.put(this.baseURL + "/campaigns/".concat(id), {
9501
9674
  campaign: params
9502
9675
  });
9503
9676
 
9504
9677
  case 2:
9505
- _yield$this$put2 = _context57.sent;
9678
+ _yield$this$put2 = _context59.sent;
9506
9679
  campaign = _yield$this$put2.campaign;
9507
- return _context57.abrupt("return", campaign);
9680
+ return _context59.abrupt("return", campaign);
9508
9681
 
9509
9682
  case 5:
9510
9683
  case "end":
9511
- return _context57.stop();
9684
+ return _context59.stop();
9512
9685
  }
9513
9686
  }
9514
- }, _callee57, this);
9687
+ }, _callee59, this);
9515
9688
  }));
9516
9689
 
9517
- function updateCampaign(_x77, _x78) {
9690
+ function updateCampaign(_x79, _x80) {
9518
9691
  return _updateCampaign.apply(this, arguments);
9519
9692
  }
9520
9693
 
@@ -9531,22 +9704,22 @@ var StreamChat = /*#__PURE__*/function () {
9531
9704
  }, {
9532
9705
  key: "deleteCampaign",
9533
9706
  value: function () {
9534
- var _deleteCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee58(id) {
9535
- return _regeneratorRuntime.wrap(function _callee58$(_context58) {
9707
+ var _deleteCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee60(id) {
9708
+ return _regeneratorRuntime.wrap(function _callee60$(_context60) {
9536
9709
  while (1) {
9537
- switch (_context58.prev = _context58.next) {
9710
+ switch (_context60.prev = _context60.next) {
9538
9711
  case 0:
9539
- return _context58.abrupt("return", this.delete(this.baseURL + "/campaigns/".concat(id)));
9712
+ return _context60.abrupt("return", this.delete(this.baseURL + "/campaigns/".concat(id)));
9540
9713
 
9541
9714
  case 1:
9542
9715
  case "end":
9543
- return _context58.stop();
9716
+ return _context60.stop();
9544
9717
  }
9545
9718
  }
9546
- }, _callee58, this);
9719
+ }, _callee60, this);
9547
9720
  }));
9548
9721
 
9549
- function deleteCampaign(_x79) {
9722
+ function deleteCampaign(_x81) {
9550
9723
  return _deleteCampaign.apply(this, arguments);
9551
9724
  }
9552
9725
 
@@ -9564,33 +9737,33 @@ var StreamChat = /*#__PURE__*/function () {
9564
9737
  }, {
9565
9738
  key: "scheduleCampaign",
9566
9739
  value: function () {
9567
- var _scheduleCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee59(id, params) {
9740
+ var _scheduleCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee61(id, params) {
9568
9741
  var sendAt, _yield$this$patch, campaign;
9569
9742
 
9570
- return _regeneratorRuntime.wrap(function _callee59$(_context59) {
9743
+ return _regeneratorRuntime.wrap(function _callee61$(_context61) {
9571
9744
  while (1) {
9572
- switch (_context59.prev = _context59.next) {
9745
+ switch (_context61.prev = _context61.next) {
9573
9746
  case 0:
9574
9747
  sendAt = params.sendAt;
9575
- _context59.next = 3;
9748
+ _context61.next = 3;
9576
9749
  return this.patch(this.baseURL + "/campaigns/".concat(id, "/schedule"), {
9577
9750
  send_at: sendAt
9578
9751
  });
9579
9752
 
9580
9753
  case 3:
9581
- _yield$this$patch = _context59.sent;
9754
+ _yield$this$patch = _context61.sent;
9582
9755
  campaign = _yield$this$patch.campaign;
9583
- return _context59.abrupt("return", campaign);
9756
+ return _context61.abrupt("return", campaign);
9584
9757
 
9585
9758
  case 6:
9586
9759
  case "end":
9587
- return _context59.stop();
9760
+ return _context61.stop();
9588
9761
  }
9589
9762
  }
9590
- }, _callee59, this);
9763
+ }, _callee61, this);
9591
9764
  }));
9592
9765
 
9593
- function scheduleCampaign(_x80, _x81) {
9766
+ function scheduleCampaign(_x82, _x83) {
9594
9767
  return _scheduleCampaign.apply(this, arguments);
9595
9768
  }
9596
9769
 
@@ -9607,30 +9780,30 @@ var StreamChat = /*#__PURE__*/function () {
9607
9780
  }, {
9608
9781
  key: "stopCampaign",
9609
9782
  value: function () {
9610
- var _stopCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee60(id) {
9783
+ var _stopCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee62(id) {
9611
9784
  var _yield$this$patch2, campaign;
9612
9785
 
9613
- return _regeneratorRuntime.wrap(function _callee60$(_context60) {
9786
+ return _regeneratorRuntime.wrap(function _callee62$(_context62) {
9614
9787
  while (1) {
9615
- switch (_context60.prev = _context60.next) {
9788
+ switch (_context62.prev = _context62.next) {
9616
9789
  case 0:
9617
- _context60.next = 2;
9790
+ _context62.next = 2;
9618
9791
  return this.patch(this.baseURL + "/campaigns/".concat(id, "/stop"));
9619
9792
 
9620
9793
  case 2:
9621
- _yield$this$patch2 = _context60.sent;
9794
+ _yield$this$patch2 = _context62.sent;
9622
9795
  campaign = _yield$this$patch2.campaign;
9623
- return _context60.abrupt("return", campaign);
9796
+ return _context62.abrupt("return", campaign);
9624
9797
 
9625
9798
  case 5:
9626
9799
  case "end":
9627
- return _context60.stop();
9800
+ return _context62.stop();
9628
9801
  }
9629
9802
  }
9630
- }, _callee60, this);
9803
+ }, _callee62, this);
9631
9804
  }));
9632
9805
 
9633
- function stopCampaign(_x82) {
9806
+ function stopCampaign(_x84) {
9634
9807
  return _stopCampaign.apply(this, arguments);
9635
9808
  }
9636
9809
 
@@ -9647,30 +9820,30 @@ var StreamChat = /*#__PURE__*/function () {
9647
9820
  }, {
9648
9821
  key: "resumeCampaign",
9649
9822
  value: function () {
9650
- var _resumeCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee61(id) {
9823
+ var _resumeCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee63(id) {
9651
9824
  var _yield$this$patch3, campaign;
9652
9825
 
9653
- return _regeneratorRuntime.wrap(function _callee61$(_context61) {
9826
+ return _regeneratorRuntime.wrap(function _callee63$(_context63) {
9654
9827
  while (1) {
9655
- switch (_context61.prev = _context61.next) {
9828
+ switch (_context63.prev = _context63.next) {
9656
9829
  case 0:
9657
- _context61.next = 2;
9830
+ _context63.next = 2;
9658
9831
  return this.patch(this.baseURL + "/campaigns/".concat(id, "/resume"));
9659
9832
 
9660
9833
  case 2:
9661
- _yield$this$patch3 = _context61.sent;
9834
+ _yield$this$patch3 = _context63.sent;
9662
9835
  campaign = _yield$this$patch3.campaign;
9663
- return _context61.abrupt("return", campaign);
9836
+ return _context63.abrupt("return", campaign);
9664
9837
 
9665
9838
  case 5:
9666
9839
  case "end":
9667
- return _context61.stop();
9840
+ return _context63.stop();
9668
9841
  }
9669
9842
  }
9670
- }, _callee61, this);
9843
+ }, _callee63, this);
9671
9844
  }));
9672
9845
 
9673
- function resumeCampaign(_x83) {
9846
+ function resumeCampaign(_x85) {
9674
9847
  return _resumeCampaign.apply(this, arguments);
9675
9848
  }
9676
9849
 
@@ -9687,33 +9860,33 @@ var StreamChat = /*#__PURE__*/function () {
9687
9860
  }, {
9688
9861
  key: "testCampaign",
9689
9862
  value: function () {
9690
- var _testCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee62(id, params) {
9863
+ var _testCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee64(id, params) {
9691
9864
  var users, _yield$this$post3, campaign;
9692
9865
 
9693
- return _regeneratorRuntime.wrap(function _callee62$(_context62) {
9866
+ return _regeneratorRuntime.wrap(function _callee64$(_context64) {
9694
9867
  while (1) {
9695
- switch (_context62.prev = _context62.next) {
9868
+ switch (_context64.prev = _context64.next) {
9696
9869
  case 0:
9697
9870
  users = params.users;
9698
- _context62.next = 3;
9871
+ _context64.next = 3;
9699
9872
  return this.post(this.baseURL + "/campaigns/".concat(id, "/test"), {
9700
9873
  users: users
9701
9874
  });
9702
9875
 
9703
9876
  case 3:
9704
- _yield$this$post3 = _context62.sent;
9877
+ _yield$this$post3 = _context64.sent;
9705
9878
  campaign = _yield$this$post3.campaign;
9706
- return _context62.abrupt("return", campaign);
9879
+ return _context64.abrupt("return", campaign);
9707
9880
 
9708
9881
  case 6:
9709
9882
  case "end":
9710
- return _context62.stop();
9883
+ return _context64.stop();
9711
9884
  }
9712
9885
  }
9713
- }, _callee62, this);
9886
+ }, _callee64, this);
9714
9887
  }));
9715
9888
 
9716
- function testCampaign(_x84, _x85) {
9889
+ function testCampaign(_x86, _x87) {
9717
9890
  return _testCampaign.apply(this, arguments);
9718
9891
  }
9719
9892
 
@@ -9729,24 +9902,24 @@ var StreamChat = /*#__PURE__*/function () {
9729
9902
  }, {
9730
9903
  key: "enrichURL",
9731
9904
  value: function () {
9732
- var _enrichURL = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee63(url) {
9733
- return _regeneratorRuntime.wrap(function _callee63$(_context63) {
9905
+ var _enrichURL = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee65(url) {
9906
+ return _regeneratorRuntime.wrap(function _callee65$(_context65) {
9734
9907
  while (1) {
9735
- switch (_context63.prev = _context63.next) {
9908
+ switch (_context65.prev = _context65.next) {
9736
9909
  case 0:
9737
- return _context63.abrupt("return", this.get(this.baseURL + "/og", {
9910
+ return _context65.abrupt("return", this.get(this.baseURL + "/og", {
9738
9911
  url: url
9739
9912
  }));
9740
9913
 
9741
9914
  case 1:
9742
9915
  case "end":
9743
- return _context63.stop();
9916
+ return _context65.stop();
9744
9917
  }
9745
9918
  }
9746
- }, _callee63, this);
9919
+ }, _callee65, this);
9747
9920
  }));
9748
9921
 
9749
- function enrichURL(_x86) {
9922
+ function enrichURL(_x88) {
9750
9923
  return _enrichURL.apply(this, arguments);
9751
9924
  }
9752
9925
 
@@ -9763,22 +9936,22 @@ var StreamChat = /*#__PURE__*/function () {
9763
9936
  }, {
9764
9937
  key: "getTask",
9765
9938
  value: function () {
9766
- var _getTask = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee64(id) {
9767
- return _regeneratorRuntime.wrap(function _callee64$(_context64) {
9939
+ var _getTask = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee66(id) {
9940
+ return _regeneratorRuntime.wrap(function _callee66$(_context66) {
9768
9941
  while (1) {
9769
- switch (_context64.prev = _context64.next) {
9942
+ switch (_context66.prev = _context66.next) {
9770
9943
  case 0:
9771
- return _context64.abrupt("return", this.get("".concat(this.baseURL, "/tasks/").concat(id)));
9944
+ return _context66.abrupt("return", this.get("".concat(this.baseURL, "/tasks/").concat(id)));
9772
9945
 
9773
9946
  case 1:
9774
9947
  case "end":
9775
- return _context64.stop();
9948
+ return _context66.stop();
9776
9949
  }
9777
9950
  }
9778
- }, _callee64, this);
9951
+ }, _callee66, this);
9779
9952
  }));
9780
9953
 
9781
- function getTask(_x87) {
9954
+ function getTask(_x89) {
9782
9955
  return _getTask.apply(this, arguments);
9783
9956
  }
9784
9957
 
@@ -9796,31 +9969,31 @@ var StreamChat = /*#__PURE__*/function () {
9796
9969
  }, {
9797
9970
  key: "deleteChannels",
9798
9971
  value: function () {
9799
- var _deleteChannels = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee65(cids) {
9972
+ var _deleteChannels = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee67(cids) {
9800
9973
  var options,
9801
- _args65 = arguments;
9802
- return _regeneratorRuntime.wrap(function _callee65$(_context65) {
9974
+ _args67 = arguments;
9975
+ return _regeneratorRuntime.wrap(function _callee67$(_context67) {
9803
9976
  while (1) {
9804
- switch (_context65.prev = _context65.next) {
9977
+ switch (_context67.prev = _context67.next) {
9805
9978
  case 0:
9806
- options = _args65.length > 1 && _args65[1] !== undefined ? _args65[1] : {};
9807
- _context65.next = 3;
9979
+ options = _args67.length > 1 && _args67[1] !== undefined ? _args67[1] : {};
9980
+ _context67.next = 3;
9808
9981
  return this.post(this.baseURL + "/channels/delete", _objectSpread({
9809
9982
  cids: cids
9810
9983
  }, options));
9811
9984
 
9812
9985
  case 3:
9813
- return _context65.abrupt("return", _context65.sent);
9986
+ return _context67.abrupt("return", _context67.sent);
9814
9987
 
9815
9988
  case 4:
9816
9989
  case "end":
9817
- return _context65.stop();
9990
+ return _context67.stop();
9818
9991
  }
9819
9992
  }
9820
- }, _callee65, this);
9993
+ }, _callee67, this);
9821
9994
  }));
9822
9995
 
9823
- function deleteChannels(_x88) {
9996
+ function deleteChannels(_x90) {
9824
9997
  return _deleteChannels.apply(this, arguments);
9825
9998
  }
9826
9999
 
@@ -9838,13 +10011,13 @@ var StreamChat = /*#__PURE__*/function () {
9838
10011
  }, {
9839
10012
  key: "deleteUsers",
9840
10013
  value: function () {
9841
- var _deleteUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee66(user_ids, options) {
9842
- return _regeneratorRuntime.wrap(function _callee66$(_context66) {
10014
+ var _deleteUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee68(user_ids, options) {
10015
+ return _regeneratorRuntime.wrap(function _callee68$(_context68) {
9843
10016
  while (1) {
9844
- switch (_context66.prev = _context66.next) {
10017
+ switch (_context68.prev = _context68.next) {
9845
10018
  case 0:
9846
10019
  if (!((options === null || options === void 0 ? void 0 : options.user) !== 'soft' && (options === null || options === void 0 ? void 0 : options.user) !== 'hard')) {
9847
- _context66.next = 2;
10020
+ _context68.next = 2;
9848
10021
  break;
9849
10022
  }
9850
10023
 
@@ -9852,7 +10025,7 @@ var StreamChat = /*#__PURE__*/function () {
9852
10025
 
9853
10026
  case 2:
9854
10027
  if (!(options.messages !== undefined && options.messages !== 'soft' && options.messages !== 'hard')) {
9855
- _context66.next = 4;
10028
+ _context68.next = 4;
9856
10029
  break;
9857
10030
  }
9858
10031
 
@@ -9860,30 +10033,30 @@ var StreamChat = /*#__PURE__*/function () {
9860
10033
 
9861
10034
  case 4:
9862
10035
  if (!(options.conversations !== undefined && options.conversations !== 'soft' && options.conversations !== 'hard')) {
9863
- _context66.next = 6;
10036
+ _context68.next = 6;
9864
10037
  break;
9865
10038
  }
9866
10039
 
9867
10040
  throw new Error('Invalid delete user options. conversations must be one of [soft hard]');
9868
10041
 
9869
10042
  case 6:
9870
- _context66.next = 8;
10043
+ _context68.next = 8;
9871
10044
  return this.post(this.baseURL + "/users/delete", _objectSpread({
9872
10045
  user_ids: user_ids
9873
10046
  }, options));
9874
10047
 
9875
10048
  case 8:
9876
- return _context66.abrupt("return", _context66.sent);
10049
+ return _context68.abrupt("return", _context68.sent);
9877
10050
 
9878
10051
  case 9:
9879
10052
  case "end":
9880
- return _context66.stop();
10053
+ return _context68.stop();
9881
10054
  }
9882
10055
  }
9883
- }, _callee66, this);
10056
+ }, _callee68, this);
9884
10057
  }));
9885
10058
 
9886
- function deleteUsers(_x89, _x90) {
10059
+ function deleteUsers(_x91, _x92) {
9887
10060
  return _deleteUsers.apply(this, arguments);
9888
10061
  }
9889
10062