stream-chat 8.11.0 → 8.12.1
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/browser.es.js +585 -558
- package/dist/browser.es.js.map +1 -1
- package/dist/browser.full-bundle.min.js +1 -1
- package/dist/browser.full-bundle.min.js.map +1 -1
- package/dist/browser.js +585 -558
- package/dist/browser.js.map +1 -1
- package/dist/index.es.js +585 -558
- package/dist/index.es.js.map +1 -1
- package/dist/index.js +585 -558
- package/dist/index.js.map +1 -1
- package/dist/types/channel.d.ts +2 -10
- package/dist/types/channel.d.ts.map +1 -1
- package/dist/types/client.d.ts +21 -17
- package/dist/types/client.d.ts.map +1 -1
- package/dist/types/types.d.ts +27 -1
- package/dist/types/types.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/channel.ts +4 -14
- package/src/client.ts +25 -16
- package/src/types.ts +30 -0
package/dist/index.es.js
CHANGED
|
@@ -1639,12 +1639,12 @@ var Channel = /*#__PURE__*/function () {
|
|
|
1639
1639
|
case 0:
|
|
1640
1640
|
options = _args4.length > 1 && _args4[1] !== undefined ? _args4[1] : {};
|
|
1641
1641
|
|
|
1642
|
-
if (!(options.offset &&
|
|
1642
|
+
if (!(options.offset && options.next)) {
|
|
1643
1643
|
_context4.next = 3;
|
|
1644
1644
|
break;
|
|
1645
1645
|
}
|
|
1646
1646
|
|
|
1647
|
-
throw Error("Cannot specify offset with
|
|
1647
|
+
throw Error("Cannot specify offset with next");
|
|
1648
1648
|
|
|
1649
1649
|
case 3:
|
|
1650
1650
|
// Return a list of channels
|
|
@@ -6840,6 +6840,8 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
6840
6840
|
|
|
6841
6841
|
_defineProperty(this, "updateUser", this.upsertUser);
|
|
6842
6842
|
|
|
6843
|
+
_defineProperty(this, "_unblockMessage", this.unblockMessage);
|
|
6844
|
+
|
|
6843
6845
|
_defineProperty(this, "markAllRead", this.markChannelsRead);
|
|
6844
6846
|
|
|
6845
6847
|
_defineProperty(this, "_isUsingServerAuth", function () {
|
|
@@ -8184,12 +8186,12 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8184
8186
|
case 0:
|
|
8185
8187
|
options = _args20.length > 2 && _args20[2] !== undefined ? _args20[2] : {};
|
|
8186
8188
|
|
|
8187
|
-
if (!(options.offset &&
|
|
8189
|
+
if (!(options.offset && options.next)) {
|
|
8188
8190
|
_context20.next = 3;
|
|
8189
8191
|
break;
|
|
8190
8192
|
}
|
|
8191
8193
|
|
|
8192
|
-
throw Error("Cannot specify offset with
|
|
8194
|
+
throw Error("Cannot specify offset with next");
|
|
8193
8195
|
|
|
8194
8196
|
case 3:
|
|
8195
8197
|
payload = _objectSpread(_objectSpread({
|
|
@@ -8350,6 +8352,36 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8350
8352
|
|
|
8351
8353
|
return getDevices;
|
|
8352
8354
|
}()
|
|
8355
|
+
}, {
|
|
8356
|
+
key: "getUnreadCount",
|
|
8357
|
+
value: function () {
|
|
8358
|
+
var _getUnreadCount = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee23(userID) {
|
|
8359
|
+
return _regeneratorRuntime.wrap(function _callee23$(_context23) {
|
|
8360
|
+
while (1) {
|
|
8361
|
+
switch (_context23.prev = _context23.next) {
|
|
8362
|
+
case 0:
|
|
8363
|
+
_context23.next = 2;
|
|
8364
|
+
return this.get(this.baseURL + '/unread', userID ? {
|
|
8365
|
+
user_id: userID
|
|
8366
|
+
} : {});
|
|
8367
|
+
|
|
8368
|
+
case 2:
|
|
8369
|
+
return _context23.abrupt("return", _context23.sent);
|
|
8370
|
+
|
|
8371
|
+
case 3:
|
|
8372
|
+
case "end":
|
|
8373
|
+
return _context23.stop();
|
|
8374
|
+
}
|
|
8375
|
+
}
|
|
8376
|
+
}, _callee23, this);
|
|
8377
|
+
}));
|
|
8378
|
+
|
|
8379
|
+
function getUnreadCount(_x25) {
|
|
8380
|
+
return _getUnreadCount.apply(this, arguments);
|
|
8381
|
+
}
|
|
8382
|
+
|
|
8383
|
+
return getUnreadCount;
|
|
8384
|
+
}()
|
|
8353
8385
|
/**
|
|
8354
8386
|
* removeDevice - Removes the device with the given id. Clientside users can only delete their own devices
|
|
8355
8387
|
*
|
|
@@ -8361,12 +8393,12 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8361
8393
|
}, {
|
|
8362
8394
|
key: "removeDevice",
|
|
8363
8395
|
value: function () {
|
|
8364
|
-
var _removeDevice = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8365
|
-
return _regeneratorRuntime.wrap(function
|
|
8396
|
+
var _removeDevice = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee24(id, userID) {
|
|
8397
|
+
return _regeneratorRuntime.wrap(function _callee24$(_context24) {
|
|
8366
8398
|
while (1) {
|
|
8367
|
-
switch (
|
|
8399
|
+
switch (_context24.prev = _context24.next) {
|
|
8368
8400
|
case 0:
|
|
8369
|
-
|
|
8401
|
+
_context24.next = 2;
|
|
8370
8402
|
return this.delete(this.baseURL + '/devices', _objectSpread({
|
|
8371
8403
|
id: id
|
|
8372
8404
|
}, userID ? {
|
|
@@ -8374,17 +8406,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8374
8406
|
} : {}));
|
|
8375
8407
|
|
|
8376
8408
|
case 2:
|
|
8377
|
-
return
|
|
8409
|
+
return _context24.abrupt("return", _context24.sent);
|
|
8378
8410
|
|
|
8379
8411
|
case 3:
|
|
8380
8412
|
case "end":
|
|
8381
|
-
return
|
|
8413
|
+
return _context24.stop();
|
|
8382
8414
|
}
|
|
8383
8415
|
}
|
|
8384
|
-
},
|
|
8416
|
+
}, _callee24, this);
|
|
8385
8417
|
}));
|
|
8386
8418
|
|
|
8387
|
-
function removeDevice(
|
|
8419
|
+
function removeDevice(_x26, _x27) {
|
|
8388
8420
|
return _removeDevice.apply(this, arguments);
|
|
8389
8421
|
}
|
|
8390
8422
|
|
|
@@ -8401,15 +8433,15 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8401
8433
|
}, {
|
|
8402
8434
|
key: "getRateLimits",
|
|
8403
8435
|
value: function () {
|
|
8404
|
-
var _getRateLimits = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8436
|
+
var _getRateLimits = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee25(params) {
|
|
8405
8437
|
var _ref7, serverSide, web, android, ios, endpoints;
|
|
8406
8438
|
|
|
8407
|
-
return _regeneratorRuntime.wrap(function
|
|
8439
|
+
return _regeneratorRuntime.wrap(function _callee25$(_context25) {
|
|
8408
8440
|
while (1) {
|
|
8409
|
-
switch (
|
|
8441
|
+
switch (_context25.prev = _context25.next) {
|
|
8410
8442
|
case 0:
|
|
8411
8443
|
_ref7 = params || {}, serverSide = _ref7.serverSide, web = _ref7.web, android = _ref7.android, ios = _ref7.ios, endpoints = _ref7.endpoints;
|
|
8412
|
-
return
|
|
8444
|
+
return _context25.abrupt("return", this.get(this.baseURL + '/rate_limits', {
|
|
8413
8445
|
server_side: serverSide,
|
|
8414
8446
|
web: web,
|
|
8415
8447
|
android: android,
|
|
@@ -8419,13 +8451,13 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8419
8451
|
|
|
8420
8452
|
case 2:
|
|
8421
8453
|
case "end":
|
|
8422
|
-
return
|
|
8454
|
+
return _context25.stop();
|
|
8423
8455
|
}
|
|
8424
8456
|
}
|
|
8425
|
-
},
|
|
8457
|
+
}, _callee25, this);
|
|
8426
8458
|
}));
|
|
8427
8459
|
|
|
8428
|
-
function getRateLimits(
|
|
8460
|
+
function getRateLimits(_x28) {
|
|
8429
8461
|
return _getRateLimits.apply(this, arguments);
|
|
8430
8462
|
}
|
|
8431
8463
|
|
|
@@ -8456,6 +8488,8 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8456
8488
|
}, {
|
|
8457
8489
|
key: "channel",
|
|
8458
8490
|
value: function channel(channelType, channelIDOrCustom) {
|
|
8491
|
+
var _custom$members;
|
|
8492
|
+
|
|
8459
8493
|
var custom = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
|
8460
8494
|
|
|
8461
8495
|
if (!this.userID && !this._isUsingServerAuth()) {
|
|
@@ -8464,18 +8498,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8464
8498
|
|
|
8465
8499
|
if (~channelType.indexOf(':')) {
|
|
8466
8500
|
throw Error("Invalid channel group ".concat(channelType, ", can't contain the : character"));
|
|
8501
|
+
} // support channel("messaging", {options})
|
|
8502
|
+
|
|
8503
|
+
|
|
8504
|
+
if (channelIDOrCustom && _typeof(channelIDOrCustom) === 'object') {
|
|
8505
|
+
return this.getChannelByMembers(channelType, channelIDOrCustom);
|
|
8506
|
+
} // // support channel("messaging", undefined, {options})
|
|
8507
|
+
|
|
8508
|
+
|
|
8509
|
+
if (!channelIDOrCustom && _typeof(custom) === 'object' && (_custom$members = custom.members) !== null && _custom$members !== void 0 && _custom$members.length) {
|
|
8510
|
+
return this.getChannelByMembers(channelType, custom);
|
|
8467
8511
|
} // support channel("messaging", null, {options})
|
|
8468
8512
|
// support channel("messaging", undefined, {options})
|
|
8469
8513
|
// support channel("messaging", "", {options})
|
|
8470
8514
|
|
|
8471
8515
|
|
|
8472
|
-
if (channelIDOrCustom
|
|
8516
|
+
if (!channelIDOrCustom) {
|
|
8473
8517
|
return new Channel(this, channelType, undefined, custom);
|
|
8474
|
-
} // support channel("messaging", {options})
|
|
8475
|
-
|
|
8476
|
-
|
|
8477
|
-
if (_typeof(channelIDOrCustom) === 'object') {
|
|
8478
|
-
return this.getChannelByMembers(channelType, channelIDOrCustom);
|
|
8479
8518
|
}
|
|
8480
8519
|
|
|
8481
8520
|
return this.getChannelById(channelType, channelIDOrCustom, custom);
|
|
@@ -8509,26 +8548,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8509
8548
|
* @return {Promise<{ users: { [key: string]: UserResponse<StreamChatGenerics> } }>} list of updated users
|
|
8510
8549
|
*/
|
|
8511
8550
|
function () {
|
|
8512
|
-
var _partialUpdateUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8513
|
-
return _regeneratorRuntime.wrap(function
|
|
8551
|
+
var _partialUpdateUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee26(partialUserObject) {
|
|
8552
|
+
return _regeneratorRuntime.wrap(function _callee26$(_context26) {
|
|
8514
8553
|
while (1) {
|
|
8515
|
-
switch (
|
|
8554
|
+
switch (_context26.prev = _context26.next) {
|
|
8516
8555
|
case 0:
|
|
8517
|
-
|
|
8556
|
+
_context26.next = 2;
|
|
8518
8557
|
return this.partialUpdateUsers([partialUserObject]);
|
|
8519
8558
|
|
|
8520
8559
|
case 2:
|
|
8521
|
-
return
|
|
8560
|
+
return _context26.abrupt("return", _context26.sent);
|
|
8522
8561
|
|
|
8523
8562
|
case 3:
|
|
8524
8563
|
case "end":
|
|
8525
|
-
return
|
|
8564
|
+
return _context26.stop();
|
|
8526
8565
|
}
|
|
8527
8566
|
}
|
|
8528
|
-
},
|
|
8567
|
+
}, _callee26, this);
|
|
8529
8568
|
}));
|
|
8530
8569
|
|
|
8531
|
-
function partialUpdateUser(
|
|
8570
|
+
function partialUpdateUser(_x29) {
|
|
8532
8571
|
return _partialUpdateUser.apply(this, arguments);
|
|
8533
8572
|
}
|
|
8534
8573
|
|
|
@@ -8545,29 +8584,29 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8545
8584
|
}, {
|
|
8546
8585
|
key: "upsertUsers",
|
|
8547
8586
|
value: function () {
|
|
8548
|
-
var _upsertUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8587
|
+
var _upsertUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee27(users) {
|
|
8549
8588
|
var userMap, _iterator4, _step4, userObject;
|
|
8550
8589
|
|
|
8551
|
-
return _regeneratorRuntime.wrap(function
|
|
8590
|
+
return _regeneratorRuntime.wrap(function _callee27$(_context27) {
|
|
8552
8591
|
while (1) {
|
|
8553
|
-
switch (
|
|
8592
|
+
switch (_context27.prev = _context27.next) {
|
|
8554
8593
|
case 0:
|
|
8555
8594
|
userMap = {};
|
|
8556
8595
|
_iterator4 = _createForOfIteratorHelper(users);
|
|
8557
|
-
|
|
8596
|
+
_context27.prev = 2;
|
|
8558
8597
|
|
|
8559
8598
|
_iterator4.s();
|
|
8560
8599
|
|
|
8561
8600
|
case 4:
|
|
8562
8601
|
if ((_step4 = _iterator4.n()).done) {
|
|
8563
|
-
|
|
8602
|
+
_context27.next = 11;
|
|
8564
8603
|
break;
|
|
8565
8604
|
}
|
|
8566
8605
|
|
|
8567
8606
|
userObject = _step4.value;
|
|
8568
8607
|
|
|
8569
8608
|
if (userObject.id) {
|
|
8570
|
-
|
|
8609
|
+
_context27.next = 8;
|
|
8571
8610
|
break;
|
|
8572
8611
|
}
|
|
8573
8612
|
|
|
@@ -8577,44 +8616,44 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8577
8616
|
userMap[userObject.id] = userObject;
|
|
8578
8617
|
|
|
8579
8618
|
case 9:
|
|
8580
|
-
|
|
8619
|
+
_context27.next = 4;
|
|
8581
8620
|
break;
|
|
8582
8621
|
|
|
8583
8622
|
case 11:
|
|
8584
|
-
|
|
8623
|
+
_context27.next = 16;
|
|
8585
8624
|
break;
|
|
8586
8625
|
|
|
8587
8626
|
case 13:
|
|
8588
|
-
|
|
8589
|
-
|
|
8627
|
+
_context27.prev = 13;
|
|
8628
|
+
_context27.t0 = _context27["catch"](2);
|
|
8590
8629
|
|
|
8591
|
-
_iterator4.e(
|
|
8630
|
+
_iterator4.e(_context27.t0);
|
|
8592
8631
|
|
|
8593
8632
|
case 16:
|
|
8594
|
-
|
|
8633
|
+
_context27.prev = 16;
|
|
8595
8634
|
|
|
8596
8635
|
_iterator4.f();
|
|
8597
8636
|
|
|
8598
|
-
return
|
|
8637
|
+
return _context27.finish(16);
|
|
8599
8638
|
|
|
8600
8639
|
case 19:
|
|
8601
|
-
|
|
8640
|
+
_context27.next = 21;
|
|
8602
8641
|
return this.post(this.baseURL + '/users', {
|
|
8603
8642
|
users: userMap
|
|
8604
8643
|
});
|
|
8605
8644
|
|
|
8606
8645
|
case 21:
|
|
8607
|
-
return
|
|
8646
|
+
return _context27.abrupt("return", _context27.sent);
|
|
8608
8647
|
|
|
8609
8648
|
case 22:
|
|
8610
8649
|
case "end":
|
|
8611
|
-
return
|
|
8650
|
+
return _context27.stop();
|
|
8612
8651
|
}
|
|
8613
8652
|
}
|
|
8614
|
-
},
|
|
8653
|
+
}, _callee27, this, [[2, 13, 16, 19]]);
|
|
8615
8654
|
}));
|
|
8616
8655
|
|
|
8617
|
-
function upsertUsers(
|
|
8656
|
+
function upsertUsers(_x30) {
|
|
8618
8657
|
return _upsertUsers.apply(this, arguments);
|
|
8619
8658
|
}
|
|
8620
8659
|
|
|
@@ -8662,72 +8701,72 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8662
8701
|
* @return {Promise<{ users: { [key: string]: UserResponse<StreamChatGenerics> } }>}
|
|
8663
8702
|
*/
|
|
8664
8703
|
function () {
|
|
8665
|
-
var _partialUpdateUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8704
|
+
var _partialUpdateUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee28(users) {
|
|
8666
8705
|
var _iterator5, _step5, userObject;
|
|
8667
8706
|
|
|
8668
|
-
return _regeneratorRuntime.wrap(function
|
|
8707
|
+
return _regeneratorRuntime.wrap(function _callee28$(_context28) {
|
|
8669
8708
|
while (1) {
|
|
8670
|
-
switch (
|
|
8709
|
+
switch (_context28.prev = _context28.next) {
|
|
8671
8710
|
case 0:
|
|
8672
8711
|
_iterator5 = _createForOfIteratorHelper(users);
|
|
8673
|
-
|
|
8712
|
+
_context28.prev = 1;
|
|
8674
8713
|
|
|
8675
8714
|
_iterator5.s();
|
|
8676
8715
|
|
|
8677
8716
|
case 3:
|
|
8678
8717
|
if ((_step5 = _iterator5.n()).done) {
|
|
8679
|
-
|
|
8718
|
+
_context28.next = 9;
|
|
8680
8719
|
break;
|
|
8681
8720
|
}
|
|
8682
8721
|
|
|
8683
8722
|
userObject = _step5.value;
|
|
8684
8723
|
|
|
8685
8724
|
if (userObject.id) {
|
|
8686
|
-
|
|
8725
|
+
_context28.next = 7;
|
|
8687
8726
|
break;
|
|
8688
8727
|
}
|
|
8689
8728
|
|
|
8690
8729
|
throw Error('User ID is required when updating a user');
|
|
8691
8730
|
|
|
8692
8731
|
case 7:
|
|
8693
|
-
|
|
8732
|
+
_context28.next = 3;
|
|
8694
8733
|
break;
|
|
8695
8734
|
|
|
8696
8735
|
case 9:
|
|
8697
|
-
|
|
8736
|
+
_context28.next = 14;
|
|
8698
8737
|
break;
|
|
8699
8738
|
|
|
8700
8739
|
case 11:
|
|
8701
|
-
|
|
8702
|
-
|
|
8740
|
+
_context28.prev = 11;
|
|
8741
|
+
_context28.t0 = _context28["catch"](1);
|
|
8703
8742
|
|
|
8704
|
-
_iterator5.e(
|
|
8743
|
+
_iterator5.e(_context28.t0);
|
|
8705
8744
|
|
|
8706
8745
|
case 14:
|
|
8707
|
-
|
|
8746
|
+
_context28.prev = 14;
|
|
8708
8747
|
|
|
8709
8748
|
_iterator5.f();
|
|
8710
8749
|
|
|
8711
|
-
return
|
|
8750
|
+
return _context28.finish(14);
|
|
8712
8751
|
|
|
8713
8752
|
case 17:
|
|
8714
|
-
|
|
8753
|
+
_context28.next = 19;
|
|
8715
8754
|
return this.patch(this.baseURL + '/users', {
|
|
8716
8755
|
users: users
|
|
8717
8756
|
});
|
|
8718
8757
|
|
|
8719
8758
|
case 19:
|
|
8720
|
-
return
|
|
8759
|
+
return _context28.abrupt("return", _context28.sent);
|
|
8721
8760
|
|
|
8722
8761
|
case 20:
|
|
8723
8762
|
case "end":
|
|
8724
|
-
return
|
|
8763
|
+
return _context28.stop();
|
|
8725
8764
|
}
|
|
8726
8765
|
}
|
|
8727
|
-
},
|
|
8766
|
+
}, _callee28, this, [[1, 11, 14, 17]]);
|
|
8728
8767
|
}));
|
|
8729
8768
|
|
|
8730
|
-
function partialUpdateUsers(
|
|
8769
|
+
function partialUpdateUsers(_x31) {
|
|
8731
8770
|
return _partialUpdateUsers.apply(this, arguments);
|
|
8732
8771
|
}
|
|
8733
8772
|
|
|
@@ -8736,26 +8775,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8736
8775
|
}, {
|
|
8737
8776
|
key: "deleteUser",
|
|
8738
8777
|
value: function () {
|
|
8739
|
-
var _deleteUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8740
|
-
return _regeneratorRuntime.wrap(function
|
|
8778
|
+
var _deleteUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee29(userID, params) {
|
|
8779
|
+
return _regeneratorRuntime.wrap(function _callee29$(_context29) {
|
|
8741
8780
|
while (1) {
|
|
8742
|
-
switch (
|
|
8781
|
+
switch (_context29.prev = _context29.next) {
|
|
8743
8782
|
case 0:
|
|
8744
|
-
|
|
8783
|
+
_context29.next = 2;
|
|
8745
8784
|
return this.delete(this.baseURL + "/users/".concat(userID), params);
|
|
8746
8785
|
|
|
8747
8786
|
case 2:
|
|
8748
|
-
return
|
|
8787
|
+
return _context29.abrupt("return", _context29.sent);
|
|
8749
8788
|
|
|
8750
8789
|
case 3:
|
|
8751
8790
|
case "end":
|
|
8752
|
-
return
|
|
8791
|
+
return _context29.stop();
|
|
8753
8792
|
}
|
|
8754
8793
|
}
|
|
8755
|
-
},
|
|
8794
|
+
}, _callee29, this);
|
|
8756
8795
|
}));
|
|
8757
8796
|
|
|
8758
|
-
function deleteUser(
|
|
8797
|
+
function deleteUser(_x32, _x33) {
|
|
8759
8798
|
return _deleteUser.apply(this, arguments);
|
|
8760
8799
|
}
|
|
8761
8800
|
|
|
@@ -8772,28 +8811,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8772
8811
|
}, {
|
|
8773
8812
|
key: "restoreUsers",
|
|
8774
8813
|
value: function () {
|
|
8775
|
-
var _restoreUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8776
|
-
return _regeneratorRuntime.wrap(function
|
|
8814
|
+
var _restoreUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee30(user_ids) {
|
|
8815
|
+
return _regeneratorRuntime.wrap(function _callee30$(_context30) {
|
|
8777
8816
|
while (1) {
|
|
8778
|
-
switch (
|
|
8817
|
+
switch (_context30.prev = _context30.next) {
|
|
8779
8818
|
case 0:
|
|
8780
|
-
|
|
8819
|
+
_context30.next = 2;
|
|
8781
8820
|
return this.post(this.baseURL + "/users/restore", {
|
|
8782
8821
|
user_ids: user_ids
|
|
8783
8822
|
});
|
|
8784
8823
|
|
|
8785
8824
|
case 2:
|
|
8786
|
-
return
|
|
8825
|
+
return _context30.abrupt("return", _context30.sent);
|
|
8787
8826
|
|
|
8788
8827
|
case 3:
|
|
8789
8828
|
case "end":
|
|
8790
|
-
return
|
|
8829
|
+
return _context30.stop();
|
|
8791
8830
|
}
|
|
8792
8831
|
}
|
|
8793
|
-
},
|
|
8832
|
+
}, _callee30, this);
|
|
8794
8833
|
}));
|
|
8795
8834
|
|
|
8796
|
-
function restoreUsers(
|
|
8835
|
+
function restoreUsers(_x34) {
|
|
8797
8836
|
return _restoreUsers.apply(this, arguments);
|
|
8798
8837
|
}
|
|
8799
8838
|
|
|
@@ -8811,26 +8850,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8811
8850
|
}, {
|
|
8812
8851
|
key: "reactivateUser",
|
|
8813
8852
|
value: function () {
|
|
8814
|
-
var _reactivateUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8815
|
-
return _regeneratorRuntime.wrap(function
|
|
8853
|
+
var _reactivateUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee31(userID, options) {
|
|
8854
|
+
return _regeneratorRuntime.wrap(function _callee31$(_context31) {
|
|
8816
8855
|
while (1) {
|
|
8817
|
-
switch (
|
|
8856
|
+
switch (_context31.prev = _context31.next) {
|
|
8818
8857
|
case 0:
|
|
8819
|
-
|
|
8858
|
+
_context31.next = 2;
|
|
8820
8859
|
return this.post(this.baseURL + "/users/".concat(userID, "/reactivate"), _objectSpread({}, options));
|
|
8821
8860
|
|
|
8822
8861
|
case 2:
|
|
8823
|
-
return
|
|
8862
|
+
return _context31.abrupt("return", _context31.sent);
|
|
8824
8863
|
|
|
8825
8864
|
case 3:
|
|
8826
8865
|
case "end":
|
|
8827
|
-
return
|
|
8866
|
+
return _context31.stop();
|
|
8828
8867
|
}
|
|
8829
8868
|
}
|
|
8830
|
-
},
|
|
8869
|
+
}, _callee31, this);
|
|
8831
8870
|
}));
|
|
8832
8871
|
|
|
8833
|
-
function reactivateUser(
|
|
8872
|
+
function reactivateUser(_x35, _x36) {
|
|
8834
8873
|
return _reactivateUser.apply(this, arguments);
|
|
8835
8874
|
}
|
|
8836
8875
|
|
|
@@ -8848,28 +8887,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8848
8887
|
}, {
|
|
8849
8888
|
key: "reactivateUsers",
|
|
8850
8889
|
value: function () {
|
|
8851
|
-
var _reactivateUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8852
|
-
return _regeneratorRuntime.wrap(function
|
|
8890
|
+
var _reactivateUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee32(user_ids, options) {
|
|
8891
|
+
return _regeneratorRuntime.wrap(function _callee32$(_context32) {
|
|
8853
8892
|
while (1) {
|
|
8854
|
-
switch (
|
|
8893
|
+
switch (_context32.prev = _context32.next) {
|
|
8855
8894
|
case 0:
|
|
8856
|
-
|
|
8895
|
+
_context32.next = 2;
|
|
8857
8896
|
return this.post(this.baseURL + "/users/reactivate", _objectSpread({
|
|
8858
8897
|
user_ids: user_ids
|
|
8859
8898
|
}, options));
|
|
8860
8899
|
|
|
8861
8900
|
case 2:
|
|
8862
|
-
return
|
|
8901
|
+
return _context32.abrupt("return", _context32.sent);
|
|
8863
8902
|
|
|
8864
8903
|
case 3:
|
|
8865
8904
|
case "end":
|
|
8866
|
-
return
|
|
8905
|
+
return _context32.stop();
|
|
8867
8906
|
}
|
|
8868
8907
|
}
|
|
8869
|
-
},
|
|
8908
|
+
}, _callee32, this);
|
|
8870
8909
|
}));
|
|
8871
8910
|
|
|
8872
|
-
function reactivateUsers(
|
|
8911
|
+
function reactivateUsers(_x37, _x38) {
|
|
8873
8912
|
return _reactivateUsers.apply(this, arguments);
|
|
8874
8913
|
}
|
|
8875
8914
|
|
|
@@ -8887,26 +8926,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8887
8926
|
}, {
|
|
8888
8927
|
key: "deactivateUser",
|
|
8889
8928
|
value: function () {
|
|
8890
|
-
var _deactivateUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8891
|
-
return _regeneratorRuntime.wrap(function
|
|
8929
|
+
var _deactivateUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee33(userID, options) {
|
|
8930
|
+
return _regeneratorRuntime.wrap(function _callee33$(_context33) {
|
|
8892
8931
|
while (1) {
|
|
8893
|
-
switch (
|
|
8932
|
+
switch (_context33.prev = _context33.next) {
|
|
8894
8933
|
case 0:
|
|
8895
|
-
|
|
8934
|
+
_context33.next = 2;
|
|
8896
8935
|
return this.post(this.baseURL + "/users/".concat(userID, "/deactivate"), _objectSpread({}, options));
|
|
8897
8936
|
|
|
8898
8937
|
case 2:
|
|
8899
|
-
return
|
|
8938
|
+
return _context33.abrupt("return", _context33.sent);
|
|
8900
8939
|
|
|
8901
8940
|
case 3:
|
|
8902
8941
|
case "end":
|
|
8903
|
-
return
|
|
8942
|
+
return _context33.stop();
|
|
8904
8943
|
}
|
|
8905
8944
|
}
|
|
8906
|
-
},
|
|
8945
|
+
}, _callee33, this);
|
|
8907
8946
|
}));
|
|
8908
8947
|
|
|
8909
|
-
function deactivateUser(
|
|
8948
|
+
function deactivateUser(_x39, _x40) {
|
|
8910
8949
|
return _deactivateUser.apply(this, arguments);
|
|
8911
8950
|
}
|
|
8912
8951
|
|
|
@@ -8924,28 +8963,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8924
8963
|
}, {
|
|
8925
8964
|
key: "deactivateUsers",
|
|
8926
8965
|
value: function () {
|
|
8927
|
-
var _deactivateUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8928
|
-
return _regeneratorRuntime.wrap(function
|
|
8966
|
+
var _deactivateUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee34(user_ids, options) {
|
|
8967
|
+
return _regeneratorRuntime.wrap(function _callee34$(_context34) {
|
|
8929
8968
|
while (1) {
|
|
8930
|
-
switch (
|
|
8969
|
+
switch (_context34.prev = _context34.next) {
|
|
8931
8970
|
case 0:
|
|
8932
|
-
|
|
8971
|
+
_context34.next = 2;
|
|
8933
8972
|
return this.post(this.baseURL + "/users/deactivate", _objectSpread({
|
|
8934
8973
|
user_ids: user_ids
|
|
8935
8974
|
}, options));
|
|
8936
8975
|
|
|
8937
8976
|
case 2:
|
|
8938
|
-
return
|
|
8977
|
+
return _context34.abrupt("return", _context34.sent);
|
|
8939
8978
|
|
|
8940
8979
|
case 3:
|
|
8941
8980
|
case "end":
|
|
8942
|
-
return
|
|
8981
|
+
return _context34.stop();
|
|
8943
8982
|
}
|
|
8944
8983
|
}
|
|
8945
|
-
},
|
|
8984
|
+
}, _callee34, this);
|
|
8946
8985
|
}));
|
|
8947
8986
|
|
|
8948
|
-
function deactivateUsers(
|
|
8987
|
+
function deactivateUsers(_x41, _x42) {
|
|
8949
8988
|
return _deactivateUsers.apply(this, arguments);
|
|
8950
8989
|
}
|
|
8951
8990
|
|
|
@@ -8954,26 +8993,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8954
8993
|
}, {
|
|
8955
8994
|
key: "exportUser",
|
|
8956
8995
|
value: function () {
|
|
8957
|
-
var _exportUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8958
|
-
return _regeneratorRuntime.wrap(function
|
|
8996
|
+
var _exportUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee35(userID, options) {
|
|
8997
|
+
return _regeneratorRuntime.wrap(function _callee35$(_context35) {
|
|
8959
8998
|
while (1) {
|
|
8960
|
-
switch (
|
|
8999
|
+
switch (_context35.prev = _context35.next) {
|
|
8961
9000
|
case 0:
|
|
8962
|
-
|
|
9001
|
+
_context35.next = 2;
|
|
8963
9002
|
return this.get(this.baseURL + "/users/".concat(userID, "/export"), _objectSpread({}, options));
|
|
8964
9003
|
|
|
8965
9004
|
case 2:
|
|
8966
|
-
return
|
|
9005
|
+
return _context35.abrupt("return", _context35.sent);
|
|
8967
9006
|
|
|
8968
9007
|
case 3:
|
|
8969
9008
|
case "end":
|
|
8970
|
-
return
|
|
9009
|
+
return _context35.stop();
|
|
8971
9010
|
}
|
|
8972
9011
|
}
|
|
8973
|
-
},
|
|
9012
|
+
}, _callee35, this);
|
|
8974
9013
|
}));
|
|
8975
9014
|
|
|
8976
|
-
function exportUser(
|
|
9015
|
+
function exportUser(_x43, _x44) {
|
|
8977
9016
|
return _exportUser.apply(this, arguments);
|
|
8978
9017
|
}
|
|
8979
9018
|
|
|
@@ -8989,28 +9028,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8989
9028
|
}, {
|
|
8990
9029
|
key: "banUser",
|
|
8991
9030
|
value: function () {
|
|
8992
|
-
var _banUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8993
|
-
return _regeneratorRuntime.wrap(function
|
|
9031
|
+
var _banUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee36(targetUserID, options) {
|
|
9032
|
+
return _regeneratorRuntime.wrap(function _callee36$(_context36) {
|
|
8994
9033
|
while (1) {
|
|
8995
|
-
switch (
|
|
9034
|
+
switch (_context36.prev = _context36.next) {
|
|
8996
9035
|
case 0:
|
|
8997
|
-
|
|
9036
|
+
_context36.next = 2;
|
|
8998
9037
|
return this.post(this.baseURL + '/moderation/ban', _objectSpread({
|
|
8999
9038
|
target_user_id: targetUserID
|
|
9000
9039
|
}, options));
|
|
9001
9040
|
|
|
9002
9041
|
case 2:
|
|
9003
|
-
return
|
|
9042
|
+
return _context36.abrupt("return", _context36.sent);
|
|
9004
9043
|
|
|
9005
9044
|
case 3:
|
|
9006
9045
|
case "end":
|
|
9007
|
-
return
|
|
9046
|
+
return _context36.stop();
|
|
9008
9047
|
}
|
|
9009
9048
|
}
|
|
9010
|
-
},
|
|
9049
|
+
}, _callee36, this);
|
|
9011
9050
|
}));
|
|
9012
9051
|
|
|
9013
|
-
function banUser(
|
|
9052
|
+
function banUser(_x45, _x46) {
|
|
9014
9053
|
return _banUser.apply(this, arguments);
|
|
9015
9054
|
}
|
|
9016
9055
|
|
|
@@ -9026,28 +9065,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9026
9065
|
}, {
|
|
9027
9066
|
key: "unbanUser",
|
|
9028
9067
|
value: function () {
|
|
9029
|
-
var _unbanUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9030
|
-
return _regeneratorRuntime.wrap(function
|
|
9068
|
+
var _unbanUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee37(targetUserID, options) {
|
|
9069
|
+
return _regeneratorRuntime.wrap(function _callee37$(_context37) {
|
|
9031
9070
|
while (1) {
|
|
9032
|
-
switch (
|
|
9071
|
+
switch (_context37.prev = _context37.next) {
|
|
9033
9072
|
case 0:
|
|
9034
|
-
|
|
9073
|
+
_context37.next = 2;
|
|
9035
9074
|
return this.delete(this.baseURL + '/moderation/ban', _objectSpread({
|
|
9036
9075
|
target_user_id: targetUserID
|
|
9037
9076
|
}, options));
|
|
9038
9077
|
|
|
9039
9078
|
case 2:
|
|
9040
|
-
return
|
|
9079
|
+
return _context37.abrupt("return", _context37.sent);
|
|
9041
9080
|
|
|
9042
9081
|
case 3:
|
|
9043
9082
|
case "end":
|
|
9044
|
-
return
|
|
9083
|
+
return _context37.stop();
|
|
9045
9084
|
}
|
|
9046
9085
|
}
|
|
9047
|
-
},
|
|
9086
|
+
}, _callee37, this);
|
|
9048
9087
|
}));
|
|
9049
9088
|
|
|
9050
|
-
function unbanUser(
|
|
9089
|
+
function unbanUser(_x47, _x48) {
|
|
9051
9090
|
return _unbanUser.apply(this, arguments);
|
|
9052
9091
|
}
|
|
9053
9092
|
|
|
@@ -9063,28 +9102,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9063
9102
|
}, {
|
|
9064
9103
|
key: "shadowBan",
|
|
9065
9104
|
value: function () {
|
|
9066
|
-
var _shadowBan = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9067
|
-
return _regeneratorRuntime.wrap(function
|
|
9105
|
+
var _shadowBan = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee38(targetUserID, options) {
|
|
9106
|
+
return _regeneratorRuntime.wrap(function _callee38$(_context38) {
|
|
9068
9107
|
while (1) {
|
|
9069
|
-
switch (
|
|
9108
|
+
switch (_context38.prev = _context38.next) {
|
|
9070
9109
|
case 0:
|
|
9071
|
-
|
|
9110
|
+
_context38.next = 2;
|
|
9072
9111
|
return this.banUser(targetUserID, _objectSpread({
|
|
9073
9112
|
shadow: true
|
|
9074
9113
|
}, options));
|
|
9075
9114
|
|
|
9076
9115
|
case 2:
|
|
9077
|
-
return
|
|
9116
|
+
return _context38.abrupt("return", _context38.sent);
|
|
9078
9117
|
|
|
9079
9118
|
case 3:
|
|
9080
9119
|
case "end":
|
|
9081
|
-
return
|
|
9120
|
+
return _context38.stop();
|
|
9082
9121
|
}
|
|
9083
9122
|
}
|
|
9084
|
-
},
|
|
9123
|
+
}, _callee38, this);
|
|
9085
9124
|
}));
|
|
9086
9125
|
|
|
9087
|
-
function shadowBan(
|
|
9126
|
+
function shadowBan(_x49, _x50) {
|
|
9088
9127
|
return _shadowBan.apply(this, arguments);
|
|
9089
9128
|
}
|
|
9090
9129
|
|
|
@@ -9100,28 +9139,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9100
9139
|
}, {
|
|
9101
9140
|
key: "removeShadowBan",
|
|
9102
9141
|
value: function () {
|
|
9103
|
-
var _removeShadowBan = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9104
|
-
return _regeneratorRuntime.wrap(function
|
|
9142
|
+
var _removeShadowBan = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee39(targetUserID, options) {
|
|
9143
|
+
return _regeneratorRuntime.wrap(function _callee39$(_context39) {
|
|
9105
9144
|
while (1) {
|
|
9106
|
-
switch (
|
|
9145
|
+
switch (_context39.prev = _context39.next) {
|
|
9107
9146
|
case 0:
|
|
9108
|
-
|
|
9147
|
+
_context39.next = 2;
|
|
9109
9148
|
return this.unbanUser(targetUserID, _objectSpread({
|
|
9110
9149
|
shadow: true
|
|
9111
9150
|
}, options));
|
|
9112
9151
|
|
|
9113
9152
|
case 2:
|
|
9114
|
-
return
|
|
9153
|
+
return _context39.abrupt("return", _context39.sent);
|
|
9115
9154
|
|
|
9116
9155
|
case 3:
|
|
9117
9156
|
case "end":
|
|
9118
|
-
return
|
|
9157
|
+
return _context39.stop();
|
|
9119
9158
|
}
|
|
9120
9159
|
}
|
|
9121
|
-
},
|
|
9160
|
+
}, _callee39, this);
|
|
9122
9161
|
}));
|
|
9123
9162
|
|
|
9124
|
-
function removeShadowBan(
|
|
9163
|
+
function removeShadowBan(_x51, _x52) {
|
|
9125
9164
|
return _removeShadowBan.apply(this, arguments);
|
|
9126
9165
|
}
|
|
9127
9166
|
|
|
@@ -9138,15 +9177,15 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9138
9177
|
}, {
|
|
9139
9178
|
key: "muteUser",
|
|
9140
9179
|
value: function () {
|
|
9141
|
-
var _muteUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9180
|
+
var _muteUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee40(targetID, userID) {
|
|
9142
9181
|
var options,
|
|
9143
|
-
|
|
9144
|
-
return _regeneratorRuntime.wrap(function
|
|
9182
|
+
_args40 = arguments;
|
|
9183
|
+
return _regeneratorRuntime.wrap(function _callee40$(_context40) {
|
|
9145
9184
|
while (1) {
|
|
9146
|
-
switch (
|
|
9185
|
+
switch (_context40.prev = _context40.next) {
|
|
9147
9186
|
case 0:
|
|
9148
|
-
options =
|
|
9149
|
-
|
|
9187
|
+
options = _args40.length > 2 && _args40[2] !== undefined ? _args40[2] : {};
|
|
9188
|
+
_context40.next = 3;
|
|
9150
9189
|
return this.post(this.baseURL + '/moderation/mute', _objectSpread(_objectSpread({
|
|
9151
9190
|
target_id: targetID
|
|
9152
9191
|
}, userID ? {
|
|
@@ -9154,17 +9193,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9154
9193
|
} : {}), options));
|
|
9155
9194
|
|
|
9156
9195
|
case 3:
|
|
9157
|
-
return
|
|
9196
|
+
return _context40.abrupt("return", _context40.sent);
|
|
9158
9197
|
|
|
9159
9198
|
case 4:
|
|
9160
9199
|
case "end":
|
|
9161
|
-
return
|
|
9200
|
+
return _context40.stop();
|
|
9162
9201
|
}
|
|
9163
9202
|
}
|
|
9164
|
-
},
|
|
9203
|
+
}, _callee40, this);
|
|
9165
9204
|
}));
|
|
9166
9205
|
|
|
9167
|
-
function muteUser(
|
|
9206
|
+
function muteUser(_x53, _x54) {
|
|
9168
9207
|
return _muteUser.apply(this, arguments);
|
|
9169
9208
|
}
|
|
9170
9209
|
|
|
@@ -9180,12 +9219,12 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9180
9219
|
}, {
|
|
9181
9220
|
key: "unmuteUser",
|
|
9182
9221
|
value: function () {
|
|
9183
|
-
var _unmuteUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9184
|
-
return _regeneratorRuntime.wrap(function
|
|
9222
|
+
var _unmuteUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee41(targetID, currentUserID) {
|
|
9223
|
+
return _regeneratorRuntime.wrap(function _callee41$(_context41) {
|
|
9185
9224
|
while (1) {
|
|
9186
|
-
switch (
|
|
9225
|
+
switch (_context41.prev = _context41.next) {
|
|
9187
9226
|
case 0:
|
|
9188
|
-
|
|
9227
|
+
_context41.next = 2;
|
|
9189
9228
|
return this.post(this.baseURL + '/moderation/unmute', _objectSpread({
|
|
9190
9229
|
target_id: targetID
|
|
9191
9230
|
}, currentUserID ? {
|
|
@@ -9193,17 +9232,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9193
9232
|
} : {}));
|
|
9194
9233
|
|
|
9195
9234
|
case 2:
|
|
9196
|
-
return
|
|
9235
|
+
return _context41.abrupt("return", _context41.sent);
|
|
9197
9236
|
|
|
9198
9237
|
case 3:
|
|
9199
9238
|
case "end":
|
|
9200
|
-
return
|
|
9239
|
+
return _context41.stop();
|
|
9201
9240
|
}
|
|
9202
9241
|
}
|
|
9203
|
-
},
|
|
9242
|
+
}, _callee41, this);
|
|
9204
9243
|
}));
|
|
9205
9244
|
|
|
9206
|
-
function unmuteUser(
|
|
9245
|
+
function unmuteUser(_x55, _x56) {
|
|
9207
9246
|
return _unmuteUser.apply(this, arguments);
|
|
9208
9247
|
}
|
|
9209
9248
|
|
|
@@ -9238,31 +9277,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9238
9277
|
}, {
|
|
9239
9278
|
key: "flagMessage",
|
|
9240
9279
|
value: function () {
|
|
9241
|
-
var _flagMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9280
|
+
var _flagMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee42(targetMessageID) {
|
|
9242
9281
|
var options,
|
|
9243
|
-
|
|
9244
|
-
return _regeneratorRuntime.wrap(function
|
|
9282
|
+
_args42 = arguments;
|
|
9283
|
+
return _regeneratorRuntime.wrap(function _callee42$(_context42) {
|
|
9245
9284
|
while (1) {
|
|
9246
|
-
switch (
|
|
9285
|
+
switch (_context42.prev = _context42.next) {
|
|
9247
9286
|
case 0:
|
|
9248
|
-
options =
|
|
9249
|
-
|
|
9287
|
+
options = _args42.length > 1 && _args42[1] !== undefined ? _args42[1] : {};
|
|
9288
|
+
_context42.next = 3;
|
|
9250
9289
|
return this.post(this.baseURL + '/moderation/flag', _objectSpread({
|
|
9251
9290
|
target_message_id: targetMessageID
|
|
9252
9291
|
}, options));
|
|
9253
9292
|
|
|
9254
9293
|
case 3:
|
|
9255
|
-
return
|
|
9294
|
+
return _context42.abrupt("return", _context42.sent);
|
|
9256
9295
|
|
|
9257
9296
|
case 4:
|
|
9258
9297
|
case "end":
|
|
9259
|
-
return
|
|
9298
|
+
return _context42.stop();
|
|
9260
9299
|
}
|
|
9261
9300
|
}
|
|
9262
|
-
},
|
|
9301
|
+
}, _callee42, this);
|
|
9263
9302
|
}));
|
|
9264
9303
|
|
|
9265
|
-
function flagMessage(
|
|
9304
|
+
function flagMessage(_x57) {
|
|
9266
9305
|
return _flagMessage.apply(this, arguments);
|
|
9267
9306
|
}
|
|
9268
9307
|
|
|
@@ -9278,31 +9317,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9278
9317
|
}, {
|
|
9279
9318
|
key: "flagUser",
|
|
9280
9319
|
value: function () {
|
|
9281
|
-
var _flagUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9320
|
+
var _flagUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee43(targetID) {
|
|
9282
9321
|
var options,
|
|
9283
|
-
|
|
9284
|
-
return _regeneratorRuntime.wrap(function
|
|
9322
|
+
_args43 = arguments;
|
|
9323
|
+
return _regeneratorRuntime.wrap(function _callee43$(_context43) {
|
|
9285
9324
|
while (1) {
|
|
9286
|
-
switch (
|
|
9325
|
+
switch (_context43.prev = _context43.next) {
|
|
9287
9326
|
case 0:
|
|
9288
|
-
options =
|
|
9289
|
-
|
|
9327
|
+
options = _args43.length > 1 && _args43[1] !== undefined ? _args43[1] : {};
|
|
9328
|
+
_context43.next = 3;
|
|
9290
9329
|
return this.post(this.baseURL + '/moderation/flag', _objectSpread({
|
|
9291
9330
|
target_user_id: targetID
|
|
9292
9331
|
}, options));
|
|
9293
9332
|
|
|
9294
9333
|
case 3:
|
|
9295
|
-
return
|
|
9334
|
+
return _context43.abrupt("return", _context43.sent);
|
|
9296
9335
|
|
|
9297
9336
|
case 4:
|
|
9298
9337
|
case "end":
|
|
9299
|
-
return
|
|
9338
|
+
return _context43.stop();
|
|
9300
9339
|
}
|
|
9301
9340
|
}
|
|
9302
|
-
},
|
|
9341
|
+
}, _callee43, this);
|
|
9303
9342
|
}));
|
|
9304
9343
|
|
|
9305
|
-
function flagUser(
|
|
9344
|
+
function flagUser(_x58) {
|
|
9306
9345
|
return _flagUser.apply(this, arguments);
|
|
9307
9346
|
}
|
|
9308
9347
|
|
|
@@ -9318,31 +9357,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9318
9357
|
}, {
|
|
9319
9358
|
key: "unflagMessage",
|
|
9320
9359
|
value: function () {
|
|
9321
|
-
var _unflagMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9360
|
+
var _unflagMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee44(targetMessageID) {
|
|
9322
9361
|
var options,
|
|
9323
|
-
|
|
9324
|
-
return _regeneratorRuntime.wrap(function
|
|
9362
|
+
_args44 = arguments;
|
|
9363
|
+
return _regeneratorRuntime.wrap(function _callee44$(_context44) {
|
|
9325
9364
|
while (1) {
|
|
9326
|
-
switch (
|
|
9365
|
+
switch (_context44.prev = _context44.next) {
|
|
9327
9366
|
case 0:
|
|
9328
|
-
options =
|
|
9329
|
-
|
|
9367
|
+
options = _args44.length > 1 && _args44[1] !== undefined ? _args44[1] : {};
|
|
9368
|
+
_context44.next = 3;
|
|
9330
9369
|
return this.post(this.baseURL + '/moderation/unflag', _objectSpread({
|
|
9331
9370
|
target_message_id: targetMessageID
|
|
9332
9371
|
}, options));
|
|
9333
9372
|
|
|
9334
9373
|
case 3:
|
|
9335
|
-
return
|
|
9374
|
+
return _context44.abrupt("return", _context44.sent);
|
|
9336
9375
|
|
|
9337
9376
|
case 4:
|
|
9338
9377
|
case "end":
|
|
9339
|
-
return
|
|
9378
|
+
return _context44.stop();
|
|
9340
9379
|
}
|
|
9341
9380
|
}
|
|
9342
|
-
},
|
|
9381
|
+
}, _callee44, this);
|
|
9343
9382
|
}));
|
|
9344
9383
|
|
|
9345
|
-
function unflagMessage(
|
|
9384
|
+
function unflagMessage(_x59) {
|
|
9346
9385
|
return _unflagMessage.apply(this, arguments);
|
|
9347
9386
|
}
|
|
9348
9387
|
|
|
@@ -9358,31 +9397,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9358
9397
|
}, {
|
|
9359
9398
|
key: "unflagUser",
|
|
9360
9399
|
value: function () {
|
|
9361
|
-
var _unflagUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9400
|
+
var _unflagUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee45(targetID) {
|
|
9362
9401
|
var options,
|
|
9363
|
-
|
|
9364
|
-
return _regeneratorRuntime.wrap(function
|
|
9402
|
+
_args45 = arguments;
|
|
9403
|
+
return _regeneratorRuntime.wrap(function _callee45$(_context45) {
|
|
9365
9404
|
while (1) {
|
|
9366
|
-
switch (
|
|
9405
|
+
switch (_context45.prev = _context45.next) {
|
|
9367
9406
|
case 0:
|
|
9368
|
-
options =
|
|
9369
|
-
|
|
9407
|
+
options = _args45.length > 1 && _args45[1] !== undefined ? _args45[1] : {};
|
|
9408
|
+
_context45.next = 3;
|
|
9370
9409
|
return this.post(this.baseURL + '/moderation/unflag', _objectSpread({
|
|
9371
9410
|
target_user_id: targetID
|
|
9372
9411
|
}, options));
|
|
9373
9412
|
|
|
9374
9413
|
case 3:
|
|
9375
|
-
return
|
|
9414
|
+
return _context45.abrupt("return", _context45.sent);
|
|
9376
9415
|
|
|
9377
9416
|
case 4:
|
|
9378
9417
|
case "end":
|
|
9379
|
-
return
|
|
9418
|
+
return _context45.stop();
|
|
9380
9419
|
}
|
|
9381
9420
|
}
|
|
9382
|
-
},
|
|
9421
|
+
}, _callee45, this);
|
|
9383
9422
|
}));
|
|
9384
9423
|
|
|
9385
|
-
function unflagUser(
|
|
9424
|
+
function unflagUser(_x60) {
|
|
9386
9425
|
return _unflagUser.apply(this, arguments);
|
|
9387
9426
|
}
|
|
9388
9427
|
|
|
@@ -9399,29 +9438,29 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9399
9438
|
}, {
|
|
9400
9439
|
key: "getCallToken",
|
|
9401
9440
|
value: function () {
|
|
9402
|
-
var _getCallToken = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9441
|
+
var _getCallToken = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee46(callID) {
|
|
9403
9442
|
var options,
|
|
9404
|
-
|
|
9405
|
-
return _regeneratorRuntime.wrap(function
|
|
9443
|
+
_args46 = arguments;
|
|
9444
|
+
return _regeneratorRuntime.wrap(function _callee46$(_context46) {
|
|
9406
9445
|
while (1) {
|
|
9407
|
-
switch (
|
|
9446
|
+
switch (_context46.prev = _context46.next) {
|
|
9408
9447
|
case 0:
|
|
9409
|
-
options =
|
|
9410
|
-
|
|
9448
|
+
options = _args46.length > 1 && _args46[1] !== undefined ? _args46[1] : {};
|
|
9449
|
+
_context46.next = 3;
|
|
9411
9450
|
return this.post(this.baseURL + "/calls/".concat(callID), _objectSpread({}, options));
|
|
9412
9451
|
|
|
9413
9452
|
case 3:
|
|
9414
|
-
return
|
|
9453
|
+
return _context46.abrupt("return", _context46.sent);
|
|
9415
9454
|
|
|
9416
9455
|
case 4:
|
|
9417
9456
|
case "end":
|
|
9418
|
-
return
|
|
9457
|
+
return _context46.stop();
|
|
9419
9458
|
}
|
|
9420
9459
|
}
|
|
9421
|
-
},
|
|
9460
|
+
}, _callee46, this);
|
|
9422
9461
|
}));
|
|
9423
9462
|
|
|
9424
|
-
function getCallToken(
|
|
9463
|
+
function getCallToken(_x61) {
|
|
9425
9464
|
return _getCallToken.apply(this, arguments);
|
|
9426
9465
|
}
|
|
9427
9466
|
|
|
@@ -9444,30 +9483,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9444
9483
|
}, {
|
|
9445
9484
|
key: "_queryFlags",
|
|
9446
9485
|
value: function () {
|
|
9447
|
-
var _queryFlags2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9486
|
+
var _queryFlags2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee47() {
|
|
9448
9487
|
var filterConditions,
|
|
9449
9488
|
options,
|
|
9450
|
-
|
|
9451
|
-
return _regeneratorRuntime.wrap(function
|
|
9489
|
+
_args47 = arguments;
|
|
9490
|
+
return _regeneratorRuntime.wrap(function _callee47$(_context47) {
|
|
9452
9491
|
while (1) {
|
|
9453
|
-
switch (
|
|
9492
|
+
switch (_context47.prev = _context47.next) {
|
|
9454
9493
|
case 0:
|
|
9455
|
-
filterConditions =
|
|
9456
|
-
options =
|
|
9457
|
-
|
|
9494
|
+
filterConditions = _args47.length > 0 && _args47[0] !== undefined ? _args47[0] : {};
|
|
9495
|
+
options = _args47.length > 1 && _args47[1] !== undefined ? _args47[1] : {};
|
|
9496
|
+
_context47.next = 4;
|
|
9458
9497
|
return this.post(this.baseURL + '/moderation/flags', _objectSpread({
|
|
9459
9498
|
filter_conditions: filterConditions
|
|
9460
9499
|
}, options));
|
|
9461
9500
|
|
|
9462
9501
|
case 4:
|
|
9463
|
-
return
|
|
9502
|
+
return _context47.abrupt("return", _context47.sent);
|
|
9464
9503
|
|
|
9465
9504
|
case 5:
|
|
9466
9505
|
case "end":
|
|
9467
|
-
return
|
|
9506
|
+
return _context47.stop();
|
|
9468
9507
|
}
|
|
9469
9508
|
}
|
|
9470
|
-
},
|
|
9509
|
+
}, _callee47, this);
|
|
9471
9510
|
}));
|
|
9472
9511
|
|
|
9473
9512
|
function _queryFlags() {
|
|
@@ -9493,30 +9532,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9493
9532
|
}, {
|
|
9494
9533
|
key: "_queryFlagReports",
|
|
9495
9534
|
value: function () {
|
|
9496
|
-
var _queryFlagReports2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9535
|
+
var _queryFlagReports2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee48() {
|
|
9497
9536
|
var filterConditions,
|
|
9498
9537
|
options,
|
|
9499
|
-
|
|
9500
|
-
return _regeneratorRuntime.wrap(function
|
|
9538
|
+
_args48 = arguments;
|
|
9539
|
+
return _regeneratorRuntime.wrap(function _callee48$(_context48) {
|
|
9501
9540
|
while (1) {
|
|
9502
|
-
switch (
|
|
9541
|
+
switch (_context48.prev = _context48.next) {
|
|
9503
9542
|
case 0:
|
|
9504
|
-
filterConditions =
|
|
9505
|
-
options =
|
|
9506
|
-
|
|
9543
|
+
filterConditions = _args48.length > 0 && _args48[0] !== undefined ? _args48[0] : {};
|
|
9544
|
+
options = _args48.length > 1 && _args48[1] !== undefined ? _args48[1] : {};
|
|
9545
|
+
_context48.next = 4;
|
|
9507
9546
|
return this.post(this.baseURL + '/moderation/reports', _objectSpread({
|
|
9508
9547
|
filter_conditions: filterConditions
|
|
9509
9548
|
}, options));
|
|
9510
9549
|
|
|
9511
9550
|
case 4:
|
|
9512
|
-
return
|
|
9551
|
+
return _context48.abrupt("return", _context48.sent);
|
|
9513
9552
|
|
|
9514
9553
|
case 5:
|
|
9515
9554
|
case "end":
|
|
9516
|
-
return
|
|
9555
|
+
return _context48.stop();
|
|
9517
9556
|
}
|
|
9518
9557
|
}
|
|
9519
|
-
},
|
|
9558
|
+
}, _callee48, this);
|
|
9520
9559
|
}));
|
|
9521
9560
|
|
|
9522
9561
|
function _queryFlagReports() {
|
|
@@ -9543,90 +9582,78 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9543
9582
|
}, {
|
|
9544
9583
|
key: "_reviewFlagReport",
|
|
9545
9584
|
value: function () {
|
|
9546
|
-
var _reviewFlagReport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9585
|
+
var _reviewFlagReport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee49(id, reviewResult) {
|
|
9547
9586
|
var options,
|
|
9548
|
-
|
|
9549
|
-
return _regeneratorRuntime.wrap(function
|
|
9587
|
+
_args49 = arguments;
|
|
9588
|
+
return _regeneratorRuntime.wrap(function _callee49$(_context49) {
|
|
9550
9589
|
while (1) {
|
|
9551
|
-
switch (
|
|
9590
|
+
switch (_context49.prev = _context49.next) {
|
|
9552
9591
|
case 0:
|
|
9553
|
-
options =
|
|
9554
|
-
|
|
9592
|
+
options = _args49.length > 2 && _args49[2] !== undefined ? _args49[2] : {};
|
|
9593
|
+
_context49.next = 3;
|
|
9555
9594
|
return this.patch(this.baseURL + "/moderation/reports/".concat(id), _objectSpread({
|
|
9556
9595
|
review_result: reviewResult
|
|
9557
9596
|
}, options));
|
|
9558
9597
|
|
|
9559
9598
|
case 3:
|
|
9560
|
-
return
|
|
9599
|
+
return _context49.abrupt("return", _context49.sent);
|
|
9561
9600
|
|
|
9562
9601
|
case 4:
|
|
9563
9602
|
case "end":
|
|
9564
|
-
return
|
|
9603
|
+
return _context49.stop();
|
|
9565
9604
|
}
|
|
9566
9605
|
}
|
|
9567
|
-
},
|
|
9606
|
+
}, _callee49, this);
|
|
9568
9607
|
}));
|
|
9569
9608
|
|
|
9570
|
-
function _reviewFlagReport(
|
|
9609
|
+
function _reviewFlagReport(_x62, _x63) {
|
|
9571
9610
|
return _reviewFlagReport2.apply(this, arguments);
|
|
9572
9611
|
}
|
|
9573
9612
|
|
|
9574
9613
|
return _reviewFlagReport;
|
|
9575
9614
|
}()
|
|
9576
9615
|
/**
|
|
9577
|
-
*
|
|
9616
|
+
* unblockMessage - unblocks message blocked by automod
|
|
9578
9617
|
*
|
|
9579
|
-
* Note: Do not use this.
|
|
9580
|
-
* It is present for internal usage only.
|
|
9581
|
-
* This function can, and will, break and/or be removed at any point in time.
|
|
9582
9618
|
*
|
|
9583
|
-
* @private
|
|
9584
9619
|
* @param {string} targetMessageID
|
|
9585
9620
|
* @param {string} [options.user_id] currentUserID, only used with serverside auth
|
|
9586
9621
|
* @returns {Promise<APIResponse>}
|
|
9587
9622
|
*/
|
|
9588
9623
|
|
|
9589
9624
|
}, {
|
|
9590
|
-
key: "
|
|
9625
|
+
key: "unblockMessage",
|
|
9591
9626
|
value: function () {
|
|
9592
|
-
var
|
|
9627
|
+
var _unblockMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee50(targetMessageID) {
|
|
9593
9628
|
var options,
|
|
9594
|
-
|
|
9595
|
-
return _regeneratorRuntime.wrap(function
|
|
9629
|
+
_args50 = arguments;
|
|
9630
|
+
return _regeneratorRuntime.wrap(function _callee50$(_context50) {
|
|
9596
9631
|
while (1) {
|
|
9597
|
-
switch (
|
|
9632
|
+
switch (_context50.prev = _context50.next) {
|
|
9598
9633
|
case 0:
|
|
9599
|
-
options =
|
|
9600
|
-
|
|
9634
|
+
options = _args50.length > 1 && _args50[1] !== undefined ? _args50[1] : {};
|
|
9635
|
+
_context50.next = 3;
|
|
9601
9636
|
return this.post(this.baseURL + '/moderation/unblock_message', _objectSpread({
|
|
9602
9637
|
target_message_id: targetMessageID
|
|
9603
9638
|
}, options));
|
|
9604
9639
|
|
|
9605
9640
|
case 3:
|
|
9606
|
-
return
|
|
9641
|
+
return _context50.abrupt("return", _context50.sent);
|
|
9607
9642
|
|
|
9608
9643
|
case 4:
|
|
9609
9644
|
case "end":
|
|
9610
|
-
return
|
|
9645
|
+
return _context50.stop();
|
|
9611
9646
|
}
|
|
9612
9647
|
}
|
|
9613
|
-
},
|
|
9648
|
+
}, _callee50, this);
|
|
9614
9649
|
}));
|
|
9615
9650
|
|
|
9616
|
-
function
|
|
9617
|
-
return
|
|
9651
|
+
function unblockMessage(_x64) {
|
|
9652
|
+
return _unblockMessage.apply(this, arguments);
|
|
9618
9653
|
}
|
|
9619
9654
|
|
|
9620
|
-
return
|
|
9621
|
-
}()
|
|
9622
|
-
/**
|
|
9623
|
-
* @deprecated use markChannelsRead instead
|
|
9624
|
-
*
|
|
9625
|
-
* markAllRead - marks all channels for this user as read
|
|
9626
|
-
* @param {MarkAllReadOptions<StreamChatGenerics>} [data]
|
|
9627
|
-
*
|
|
9628
|
-
* @return {Promise<APIResponse>}
|
|
9629
|
-
*/
|
|
9655
|
+
return unblockMessage;
|
|
9656
|
+
}() // alias for backwards compatibility
|
|
9630
9657
|
|
|
9631
9658
|
}, {
|
|
9632
9659
|
key: "markChannelsRead",
|
|
@@ -9640,23 +9667,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9640
9667
|
* @return {Promise<APIResponse>}
|
|
9641
9668
|
*/
|
|
9642
9669
|
function () {
|
|
9643
|
-
var _markChannelsRead = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9670
|
+
var _markChannelsRead = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee51() {
|
|
9644
9671
|
var data,
|
|
9645
|
-
|
|
9646
|
-
return _regeneratorRuntime.wrap(function
|
|
9672
|
+
_args51 = arguments;
|
|
9673
|
+
return _regeneratorRuntime.wrap(function _callee51$(_context51) {
|
|
9647
9674
|
while (1) {
|
|
9648
|
-
switch (
|
|
9675
|
+
switch (_context51.prev = _context51.next) {
|
|
9649
9676
|
case 0:
|
|
9650
|
-
data =
|
|
9651
|
-
|
|
9677
|
+
data = _args51.length > 0 && _args51[0] !== undefined ? _args51[0] : {};
|
|
9678
|
+
_context51.next = 3;
|
|
9652
9679
|
return this.post(this.baseURL + '/channels/read', _objectSpread({}, data));
|
|
9653
9680
|
|
|
9654
9681
|
case 3:
|
|
9655
9682
|
case "end":
|
|
9656
|
-
return
|
|
9683
|
+
return _context51.stop();
|
|
9657
9684
|
}
|
|
9658
9685
|
}
|
|
9659
|
-
},
|
|
9686
|
+
}, _callee51, this);
|
|
9660
9687
|
}));
|
|
9661
9688
|
|
|
9662
9689
|
function markChannelsRead() {
|
|
@@ -9731,28 +9758,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9731
9758
|
}, {
|
|
9732
9759
|
key: "translateMessage",
|
|
9733
9760
|
value: function () {
|
|
9734
|
-
var _translateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9735
|
-
return _regeneratorRuntime.wrap(function
|
|
9761
|
+
var _translateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee52(messageId, language) {
|
|
9762
|
+
return _regeneratorRuntime.wrap(function _callee52$(_context52) {
|
|
9736
9763
|
while (1) {
|
|
9737
|
-
switch (
|
|
9764
|
+
switch (_context52.prev = _context52.next) {
|
|
9738
9765
|
case 0:
|
|
9739
|
-
|
|
9766
|
+
_context52.next = 2;
|
|
9740
9767
|
return this.post(this.baseURL + "/messages/".concat(messageId, "/translate"), {
|
|
9741
9768
|
language: language
|
|
9742
9769
|
});
|
|
9743
9770
|
|
|
9744
9771
|
case 2:
|
|
9745
|
-
return
|
|
9772
|
+
return _context52.abrupt("return", _context52.sent);
|
|
9746
9773
|
|
|
9747
9774
|
case 3:
|
|
9748
9775
|
case "end":
|
|
9749
|
-
return
|
|
9776
|
+
return _context52.stop();
|
|
9750
9777
|
}
|
|
9751
9778
|
}
|
|
9752
|
-
},
|
|
9779
|
+
}, _callee52, this);
|
|
9753
9780
|
}));
|
|
9754
9781
|
|
|
9755
|
-
function translateMessage(
|
|
9782
|
+
function translateMessage(_x65, _x66) {
|
|
9756
9783
|
return _translateMessage.apply(this, arguments);
|
|
9757
9784
|
}
|
|
9758
9785
|
|
|
@@ -9854,14 +9881,14 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9854
9881
|
}, {
|
|
9855
9882
|
key: "updateMessage",
|
|
9856
9883
|
value: function () {
|
|
9857
|
-
var _updateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9884
|
+
var _updateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee53(message, userId, options) {
|
|
9858
9885
|
var clonedMessage, reservedMessageFields;
|
|
9859
|
-
return _regeneratorRuntime.wrap(function
|
|
9886
|
+
return _regeneratorRuntime.wrap(function _callee53$(_context53) {
|
|
9860
9887
|
while (1) {
|
|
9861
|
-
switch (
|
|
9888
|
+
switch (_context53.prev = _context53.next) {
|
|
9862
9889
|
case 0:
|
|
9863
9890
|
if (message.id) {
|
|
9864
|
-
|
|
9891
|
+
_context53.next = 2;
|
|
9865
9892
|
break;
|
|
9866
9893
|
}
|
|
9867
9894
|
|
|
@@ -9898,23 +9925,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9898
9925
|
});
|
|
9899
9926
|
}
|
|
9900
9927
|
|
|
9901
|
-
|
|
9928
|
+
_context53.next = 10;
|
|
9902
9929
|
return this.post(this.baseURL + "/messages/".concat(message.id), _objectSpread({
|
|
9903
9930
|
message: clonedMessage
|
|
9904
9931
|
}, options));
|
|
9905
9932
|
|
|
9906
9933
|
case 10:
|
|
9907
|
-
return
|
|
9934
|
+
return _context53.abrupt("return", _context53.sent);
|
|
9908
9935
|
|
|
9909
9936
|
case 11:
|
|
9910
9937
|
case "end":
|
|
9911
|
-
return
|
|
9938
|
+
return _context53.stop();
|
|
9912
9939
|
}
|
|
9913
9940
|
}
|
|
9914
|
-
},
|
|
9941
|
+
}, _callee53, this);
|
|
9915
9942
|
}));
|
|
9916
9943
|
|
|
9917
|
-
function updateMessage(
|
|
9944
|
+
function updateMessage(_x67, _x68, _x69) {
|
|
9918
9945
|
return _updateMessage.apply(this, arguments);
|
|
9919
9946
|
}
|
|
9920
9947
|
|
|
@@ -9937,14 +9964,14 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9937
9964
|
}, {
|
|
9938
9965
|
key: "partialUpdateMessage",
|
|
9939
9966
|
value: function () {
|
|
9940
|
-
var _partialUpdateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9967
|
+
var _partialUpdateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee54(id, partialMessageObject, userId, options) {
|
|
9941
9968
|
var user;
|
|
9942
|
-
return _regeneratorRuntime.wrap(function
|
|
9969
|
+
return _regeneratorRuntime.wrap(function _callee54$(_context54) {
|
|
9943
9970
|
while (1) {
|
|
9944
|
-
switch (
|
|
9971
|
+
switch (_context54.prev = _context54.next) {
|
|
9945
9972
|
case 0:
|
|
9946
9973
|
if (id) {
|
|
9947
|
-
|
|
9974
|
+
_context54.next = 2;
|
|
9948
9975
|
break;
|
|
9949
9976
|
}
|
|
9950
9977
|
|
|
@@ -9959,23 +9986,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9959
9986
|
};
|
|
9960
9987
|
}
|
|
9961
9988
|
|
|
9962
|
-
|
|
9989
|
+
_context54.next = 6;
|
|
9963
9990
|
return this.put(this.baseURL + "/messages/".concat(id), _objectSpread(_objectSpread(_objectSpread({}, partialMessageObject), options), {}, {
|
|
9964
9991
|
user: user
|
|
9965
9992
|
}));
|
|
9966
9993
|
|
|
9967
9994
|
case 6:
|
|
9968
|
-
return
|
|
9995
|
+
return _context54.abrupt("return", _context54.sent);
|
|
9969
9996
|
|
|
9970
9997
|
case 7:
|
|
9971
9998
|
case "end":
|
|
9972
|
-
return
|
|
9999
|
+
return _context54.stop();
|
|
9973
10000
|
}
|
|
9974
10001
|
}
|
|
9975
|
-
},
|
|
10002
|
+
}, _callee54, this);
|
|
9976
10003
|
}));
|
|
9977
10004
|
|
|
9978
|
-
function partialUpdateMessage(
|
|
10005
|
+
function partialUpdateMessage(_x70, _x71, _x72, _x73) {
|
|
9979
10006
|
return _partialUpdateMessage.apply(this, arguments);
|
|
9980
10007
|
}
|
|
9981
10008
|
|
|
@@ -9984,11 +10011,11 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9984
10011
|
}, {
|
|
9985
10012
|
key: "deleteMessage",
|
|
9986
10013
|
value: function () {
|
|
9987
|
-
var _deleteMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10014
|
+
var _deleteMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee55(messageID, hardDelete) {
|
|
9988
10015
|
var params;
|
|
9989
|
-
return _regeneratorRuntime.wrap(function
|
|
10016
|
+
return _regeneratorRuntime.wrap(function _callee55$(_context55) {
|
|
9990
10017
|
while (1) {
|
|
9991
|
-
switch (
|
|
10018
|
+
switch (_context55.prev = _context55.next) {
|
|
9992
10019
|
case 0:
|
|
9993
10020
|
params = {};
|
|
9994
10021
|
|
|
@@ -9998,21 +10025,21 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9998
10025
|
};
|
|
9999
10026
|
}
|
|
10000
10027
|
|
|
10001
|
-
|
|
10028
|
+
_context55.next = 4;
|
|
10002
10029
|
return this.delete(this.baseURL + "/messages/".concat(messageID), params);
|
|
10003
10030
|
|
|
10004
10031
|
case 4:
|
|
10005
|
-
return
|
|
10032
|
+
return _context55.abrupt("return", _context55.sent);
|
|
10006
10033
|
|
|
10007
10034
|
case 5:
|
|
10008
10035
|
case "end":
|
|
10009
|
-
return
|
|
10036
|
+
return _context55.stop();
|
|
10010
10037
|
}
|
|
10011
10038
|
}
|
|
10012
|
-
},
|
|
10039
|
+
}, _callee55, this);
|
|
10013
10040
|
}));
|
|
10014
10041
|
|
|
10015
|
-
function deleteMessage(
|
|
10042
|
+
function deleteMessage(_x74, _x75) {
|
|
10016
10043
|
return _deleteMessage.apply(this, arguments);
|
|
10017
10044
|
}
|
|
10018
10045
|
|
|
@@ -10021,26 +10048,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10021
10048
|
}, {
|
|
10022
10049
|
key: "getMessage",
|
|
10023
10050
|
value: function () {
|
|
10024
|
-
var _getMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10025
|
-
return _regeneratorRuntime.wrap(function
|
|
10051
|
+
var _getMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee56(messageID) {
|
|
10052
|
+
return _regeneratorRuntime.wrap(function _callee56$(_context56) {
|
|
10026
10053
|
while (1) {
|
|
10027
|
-
switch (
|
|
10054
|
+
switch (_context56.prev = _context56.next) {
|
|
10028
10055
|
case 0:
|
|
10029
|
-
|
|
10056
|
+
_context56.next = 2;
|
|
10030
10057
|
return this.get(this.baseURL + "/messages/".concat(encodeURIComponent(messageID)));
|
|
10031
10058
|
|
|
10032
10059
|
case 2:
|
|
10033
|
-
return
|
|
10060
|
+
return _context56.abrupt("return", _context56.sent);
|
|
10034
10061
|
|
|
10035
10062
|
case 3:
|
|
10036
10063
|
case "end":
|
|
10037
|
-
return
|
|
10064
|
+
return _context56.stop();
|
|
10038
10065
|
}
|
|
10039
10066
|
}
|
|
10040
|
-
},
|
|
10067
|
+
}, _callee56, this);
|
|
10041
10068
|
}));
|
|
10042
10069
|
|
|
10043
|
-
function getMessage(
|
|
10070
|
+
function getMessage(_x76) {
|
|
10044
10071
|
return _getMessage.apply(this, arguments);
|
|
10045
10072
|
}
|
|
10046
10073
|
|
|
@@ -10049,7 +10076,7 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10049
10076
|
}, {
|
|
10050
10077
|
key: "getUserAgent",
|
|
10051
10078
|
value: function getUserAgent() {
|
|
10052
|
-
return this.userAgent || "stream-chat-javascript-client-".concat(this.node ? 'node' : 'browser', "-", "8.
|
|
10079
|
+
return this.userAgent || "stream-chat-javascript-client-".concat(this.node ? 'node' : 'browser', "-", "8.12.1");
|
|
10053
10080
|
}
|
|
10054
10081
|
}, {
|
|
10055
10082
|
key: "setUserAgent",
|
|
@@ -10268,28 +10295,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10268
10295
|
}, {
|
|
10269
10296
|
key: "sendUserCustomEvent",
|
|
10270
10297
|
value: function () {
|
|
10271
|
-
var _sendUserCustomEvent = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10272
|
-
return _regeneratorRuntime.wrap(function
|
|
10298
|
+
var _sendUserCustomEvent = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee57(targetUserID, event) {
|
|
10299
|
+
return _regeneratorRuntime.wrap(function _callee57$(_context57) {
|
|
10273
10300
|
while (1) {
|
|
10274
|
-
switch (
|
|
10301
|
+
switch (_context57.prev = _context57.next) {
|
|
10275
10302
|
case 0:
|
|
10276
|
-
|
|
10303
|
+
_context57.next = 2;
|
|
10277
10304
|
return this.post("".concat(this.baseURL, "/users/").concat(targetUserID, "/event"), {
|
|
10278
10305
|
event: event
|
|
10279
10306
|
});
|
|
10280
10307
|
|
|
10281
10308
|
case 2:
|
|
10282
|
-
return
|
|
10309
|
+
return _context57.abrupt("return", _context57.sent);
|
|
10283
10310
|
|
|
10284
10311
|
case 3:
|
|
10285
10312
|
case "end":
|
|
10286
|
-
return
|
|
10313
|
+
return _context57.stop();
|
|
10287
10314
|
}
|
|
10288
10315
|
}
|
|
10289
|
-
},
|
|
10316
|
+
}, _callee57, this);
|
|
10290
10317
|
}));
|
|
10291
10318
|
|
|
10292
|
-
function sendUserCustomEvent(
|
|
10319
|
+
function sendUserCustomEvent(_x77, _x78) {
|
|
10293
10320
|
return _sendUserCustomEvent.apply(this, arguments);
|
|
10294
10321
|
}
|
|
10295
10322
|
|
|
@@ -10357,32 +10384,32 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10357
10384
|
}, {
|
|
10358
10385
|
key: "createSegment",
|
|
10359
10386
|
value: function () {
|
|
10360
|
-
var _createSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10387
|
+
var _createSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee58(params) {
|
|
10361
10388
|
var _yield$this$post, segment;
|
|
10362
10389
|
|
|
10363
|
-
return _regeneratorRuntime.wrap(function
|
|
10390
|
+
return _regeneratorRuntime.wrap(function _callee58$(_context58) {
|
|
10364
10391
|
while (1) {
|
|
10365
|
-
switch (
|
|
10392
|
+
switch (_context58.prev = _context58.next) {
|
|
10366
10393
|
case 0:
|
|
10367
|
-
|
|
10394
|
+
_context58.next = 2;
|
|
10368
10395
|
return this.post(this.baseURL + "/segments", {
|
|
10369
10396
|
segment: params
|
|
10370
10397
|
});
|
|
10371
10398
|
|
|
10372
10399
|
case 2:
|
|
10373
|
-
_yield$this$post =
|
|
10400
|
+
_yield$this$post = _context58.sent;
|
|
10374
10401
|
segment = _yield$this$post.segment;
|
|
10375
|
-
return
|
|
10402
|
+
return _context58.abrupt("return", segment);
|
|
10376
10403
|
|
|
10377
10404
|
case 5:
|
|
10378
10405
|
case "end":
|
|
10379
|
-
return
|
|
10406
|
+
return _context58.stop();
|
|
10380
10407
|
}
|
|
10381
10408
|
}
|
|
10382
|
-
},
|
|
10409
|
+
}, _callee58, this);
|
|
10383
10410
|
}));
|
|
10384
10411
|
|
|
10385
|
-
function createSegment(
|
|
10412
|
+
function createSegment(_x79) {
|
|
10386
10413
|
return _createSegment.apply(this, arguments);
|
|
10387
10414
|
}
|
|
10388
10415
|
|
|
@@ -10398,15 +10425,15 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10398
10425
|
}, {
|
|
10399
10426
|
key: "querySegments",
|
|
10400
10427
|
value: function () {
|
|
10401
|
-
var _querySegments = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10428
|
+
var _querySegments = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee59(filters) {
|
|
10402
10429
|
var options,
|
|
10403
|
-
|
|
10404
|
-
return _regeneratorRuntime.wrap(function
|
|
10430
|
+
_args59 = arguments;
|
|
10431
|
+
return _regeneratorRuntime.wrap(function _callee59$(_context59) {
|
|
10405
10432
|
while (1) {
|
|
10406
|
-
switch (
|
|
10433
|
+
switch (_context59.prev = _context59.next) {
|
|
10407
10434
|
case 0:
|
|
10408
|
-
options =
|
|
10409
|
-
|
|
10435
|
+
options = _args59.length > 1 && _args59[1] !== undefined ? _args59[1] : {};
|
|
10436
|
+
_context59.next = 3;
|
|
10410
10437
|
return this.get(this.baseURL + "/segments", {
|
|
10411
10438
|
payload: _objectSpread({
|
|
10412
10439
|
filter_conditions: filters
|
|
@@ -10414,17 +10441,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10414
10441
|
});
|
|
10415
10442
|
|
|
10416
10443
|
case 3:
|
|
10417
|
-
return
|
|
10444
|
+
return _context59.abrupt("return", _context59.sent);
|
|
10418
10445
|
|
|
10419
10446
|
case 4:
|
|
10420
10447
|
case "end":
|
|
10421
|
-
return
|
|
10448
|
+
return _context59.stop();
|
|
10422
10449
|
}
|
|
10423
10450
|
}
|
|
10424
|
-
},
|
|
10451
|
+
}, _callee59, this);
|
|
10425
10452
|
}));
|
|
10426
10453
|
|
|
10427
|
-
function querySegments(
|
|
10454
|
+
function querySegments(_x80) {
|
|
10428
10455
|
return _querySegments.apply(this, arguments);
|
|
10429
10456
|
}
|
|
10430
10457
|
|
|
@@ -10442,32 +10469,32 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10442
10469
|
}, {
|
|
10443
10470
|
key: "updateSegment",
|
|
10444
10471
|
value: function () {
|
|
10445
|
-
var _updateSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10472
|
+
var _updateSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee60(id, params) {
|
|
10446
10473
|
var _yield$this$put, segment;
|
|
10447
10474
|
|
|
10448
|
-
return _regeneratorRuntime.wrap(function
|
|
10475
|
+
return _regeneratorRuntime.wrap(function _callee60$(_context60) {
|
|
10449
10476
|
while (1) {
|
|
10450
|
-
switch (
|
|
10477
|
+
switch (_context60.prev = _context60.next) {
|
|
10451
10478
|
case 0:
|
|
10452
|
-
|
|
10479
|
+
_context60.next = 2;
|
|
10453
10480
|
return this.put(this.baseURL + "/segments/".concat(id), {
|
|
10454
10481
|
segment: params
|
|
10455
10482
|
});
|
|
10456
10483
|
|
|
10457
10484
|
case 2:
|
|
10458
|
-
_yield$this$put =
|
|
10485
|
+
_yield$this$put = _context60.sent;
|
|
10459
10486
|
segment = _yield$this$put.segment;
|
|
10460
|
-
return
|
|
10487
|
+
return _context60.abrupt("return", segment);
|
|
10461
10488
|
|
|
10462
10489
|
case 5:
|
|
10463
10490
|
case "end":
|
|
10464
|
-
return
|
|
10491
|
+
return _context60.stop();
|
|
10465
10492
|
}
|
|
10466
10493
|
}
|
|
10467
|
-
},
|
|
10494
|
+
}, _callee60, this);
|
|
10468
10495
|
}));
|
|
10469
10496
|
|
|
10470
|
-
function updateSegment(
|
|
10497
|
+
function updateSegment(_x81, _x82) {
|
|
10471
10498
|
return _updateSegment.apply(this, arguments);
|
|
10472
10499
|
}
|
|
10473
10500
|
|
|
@@ -10484,22 +10511,22 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10484
10511
|
}, {
|
|
10485
10512
|
key: "deleteSegment",
|
|
10486
10513
|
value: function () {
|
|
10487
|
-
var _deleteSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10488
|
-
return _regeneratorRuntime.wrap(function
|
|
10514
|
+
var _deleteSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee61(id) {
|
|
10515
|
+
return _regeneratorRuntime.wrap(function _callee61$(_context61) {
|
|
10489
10516
|
while (1) {
|
|
10490
|
-
switch (
|
|
10517
|
+
switch (_context61.prev = _context61.next) {
|
|
10491
10518
|
case 0:
|
|
10492
|
-
return
|
|
10519
|
+
return _context61.abrupt("return", this.delete(this.baseURL + "/segments/".concat(id)));
|
|
10493
10520
|
|
|
10494
10521
|
case 1:
|
|
10495
10522
|
case "end":
|
|
10496
|
-
return
|
|
10523
|
+
return _context61.stop();
|
|
10497
10524
|
}
|
|
10498
10525
|
}
|
|
10499
|
-
},
|
|
10526
|
+
}, _callee61, this);
|
|
10500
10527
|
}));
|
|
10501
10528
|
|
|
10502
|
-
function deleteSegment(
|
|
10529
|
+
function deleteSegment(_x83) {
|
|
10503
10530
|
return _deleteSegment.apply(this, arguments);
|
|
10504
10531
|
}
|
|
10505
10532
|
|
|
@@ -10516,32 +10543,32 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10516
10543
|
}, {
|
|
10517
10544
|
key: "createCampaign",
|
|
10518
10545
|
value: function () {
|
|
10519
|
-
var _createCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10546
|
+
var _createCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee62(params) {
|
|
10520
10547
|
var _yield$this$post2, campaign;
|
|
10521
10548
|
|
|
10522
|
-
return _regeneratorRuntime.wrap(function
|
|
10549
|
+
return _regeneratorRuntime.wrap(function _callee62$(_context62) {
|
|
10523
10550
|
while (1) {
|
|
10524
|
-
switch (
|
|
10551
|
+
switch (_context62.prev = _context62.next) {
|
|
10525
10552
|
case 0:
|
|
10526
|
-
|
|
10553
|
+
_context62.next = 2;
|
|
10527
10554
|
return this.post(this.baseURL + "/campaigns", {
|
|
10528
10555
|
campaign: params
|
|
10529
10556
|
});
|
|
10530
10557
|
|
|
10531
10558
|
case 2:
|
|
10532
|
-
_yield$this$post2 =
|
|
10559
|
+
_yield$this$post2 = _context62.sent;
|
|
10533
10560
|
campaign = _yield$this$post2.campaign;
|
|
10534
|
-
return
|
|
10561
|
+
return _context62.abrupt("return", campaign);
|
|
10535
10562
|
|
|
10536
10563
|
case 5:
|
|
10537
10564
|
case "end":
|
|
10538
|
-
return
|
|
10565
|
+
return _context62.stop();
|
|
10539
10566
|
}
|
|
10540
10567
|
}
|
|
10541
|
-
},
|
|
10568
|
+
}, _callee62, this);
|
|
10542
10569
|
}));
|
|
10543
10570
|
|
|
10544
|
-
function createCampaign(
|
|
10571
|
+
function createCampaign(_x84) {
|
|
10545
10572
|
return _createCampaign.apply(this, arguments);
|
|
10546
10573
|
}
|
|
10547
10574
|
|
|
@@ -10557,15 +10584,15 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10557
10584
|
}, {
|
|
10558
10585
|
key: "queryCampaigns",
|
|
10559
10586
|
value: function () {
|
|
10560
|
-
var _queryCampaigns = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10587
|
+
var _queryCampaigns = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee63(filters) {
|
|
10561
10588
|
var options,
|
|
10562
|
-
|
|
10563
|
-
return _regeneratorRuntime.wrap(function
|
|
10589
|
+
_args63 = arguments;
|
|
10590
|
+
return _regeneratorRuntime.wrap(function _callee63$(_context63) {
|
|
10564
10591
|
while (1) {
|
|
10565
|
-
switch (
|
|
10592
|
+
switch (_context63.prev = _context63.next) {
|
|
10566
10593
|
case 0:
|
|
10567
|
-
options =
|
|
10568
|
-
|
|
10594
|
+
options = _args63.length > 1 && _args63[1] !== undefined ? _args63[1] : {};
|
|
10595
|
+
_context63.next = 3;
|
|
10569
10596
|
return this.get(this.baseURL + "/campaigns", {
|
|
10570
10597
|
payload: _objectSpread({
|
|
10571
10598
|
filter_conditions: filters
|
|
@@ -10573,17 +10600,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10573
10600
|
});
|
|
10574
10601
|
|
|
10575
10602
|
case 3:
|
|
10576
|
-
return
|
|
10603
|
+
return _context63.abrupt("return", _context63.sent);
|
|
10577
10604
|
|
|
10578
10605
|
case 4:
|
|
10579
10606
|
case "end":
|
|
10580
|
-
return
|
|
10607
|
+
return _context63.stop();
|
|
10581
10608
|
}
|
|
10582
10609
|
}
|
|
10583
|
-
},
|
|
10610
|
+
}, _callee63, this);
|
|
10584
10611
|
}));
|
|
10585
10612
|
|
|
10586
|
-
function queryCampaigns(
|
|
10613
|
+
function queryCampaigns(_x85) {
|
|
10587
10614
|
return _queryCampaigns.apply(this, arguments);
|
|
10588
10615
|
}
|
|
10589
10616
|
|
|
@@ -10601,32 +10628,32 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10601
10628
|
}, {
|
|
10602
10629
|
key: "updateCampaign",
|
|
10603
10630
|
value: function () {
|
|
10604
|
-
var _updateCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10631
|
+
var _updateCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee64(id, params) {
|
|
10605
10632
|
var _yield$this$put2, campaign;
|
|
10606
10633
|
|
|
10607
|
-
return _regeneratorRuntime.wrap(function
|
|
10634
|
+
return _regeneratorRuntime.wrap(function _callee64$(_context64) {
|
|
10608
10635
|
while (1) {
|
|
10609
|
-
switch (
|
|
10636
|
+
switch (_context64.prev = _context64.next) {
|
|
10610
10637
|
case 0:
|
|
10611
|
-
|
|
10638
|
+
_context64.next = 2;
|
|
10612
10639
|
return this.put(this.baseURL + "/campaigns/".concat(id), {
|
|
10613
10640
|
campaign: params
|
|
10614
10641
|
});
|
|
10615
10642
|
|
|
10616
10643
|
case 2:
|
|
10617
|
-
_yield$this$put2 =
|
|
10644
|
+
_yield$this$put2 = _context64.sent;
|
|
10618
10645
|
campaign = _yield$this$put2.campaign;
|
|
10619
|
-
return
|
|
10646
|
+
return _context64.abrupt("return", campaign);
|
|
10620
10647
|
|
|
10621
10648
|
case 5:
|
|
10622
10649
|
case "end":
|
|
10623
|
-
return
|
|
10650
|
+
return _context64.stop();
|
|
10624
10651
|
}
|
|
10625
10652
|
}
|
|
10626
|
-
},
|
|
10653
|
+
}, _callee64, this);
|
|
10627
10654
|
}));
|
|
10628
10655
|
|
|
10629
|
-
function updateCampaign(
|
|
10656
|
+
function updateCampaign(_x86, _x87) {
|
|
10630
10657
|
return _updateCampaign.apply(this, arguments);
|
|
10631
10658
|
}
|
|
10632
10659
|
|
|
@@ -10643,25 +10670,25 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10643
10670
|
}, {
|
|
10644
10671
|
key: "deleteCampaign",
|
|
10645
10672
|
value: function () {
|
|
10646
|
-
var _deleteCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10673
|
+
var _deleteCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee65(id) {
|
|
10647
10674
|
var params,
|
|
10648
|
-
|
|
10649
|
-
return _regeneratorRuntime.wrap(function
|
|
10675
|
+
_args65 = arguments;
|
|
10676
|
+
return _regeneratorRuntime.wrap(function _callee65$(_context65) {
|
|
10650
10677
|
while (1) {
|
|
10651
|
-
switch (
|
|
10678
|
+
switch (_context65.prev = _context65.next) {
|
|
10652
10679
|
case 0:
|
|
10653
|
-
params =
|
|
10654
|
-
return
|
|
10680
|
+
params = _args65.length > 1 && _args65[1] !== undefined ? _args65[1] : {};
|
|
10681
|
+
return _context65.abrupt("return", this.delete(this.baseURL + "/campaigns/".concat(id), params));
|
|
10655
10682
|
|
|
10656
10683
|
case 2:
|
|
10657
10684
|
case "end":
|
|
10658
|
-
return
|
|
10685
|
+
return _context65.stop();
|
|
10659
10686
|
}
|
|
10660
10687
|
}
|
|
10661
|
-
},
|
|
10688
|
+
}, _callee65, this);
|
|
10662
10689
|
}));
|
|
10663
10690
|
|
|
10664
|
-
function deleteCampaign(
|
|
10691
|
+
function deleteCampaign(_x88) {
|
|
10665
10692
|
return _deleteCampaign.apply(this, arguments);
|
|
10666
10693
|
}
|
|
10667
10694
|
|
|
@@ -10679,33 +10706,33 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10679
10706
|
}, {
|
|
10680
10707
|
key: "scheduleCampaign",
|
|
10681
10708
|
value: function () {
|
|
10682
|
-
var _scheduleCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10709
|
+
var _scheduleCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee66(id, params) {
|
|
10683
10710
|
var scheduledFor, _yield$this$patch, campaign;
|
|
10684
10711
|
|
|
10685
|
-
return _regeneratorRuntime.wrap(function
|
|
10712
|
+
return _regeneratorRuntime.wrap(function _callee66$(_context66) {
|
|
10686
10713
|
while (1) {
|
|
10687
|
-
switch (
|
|
10714
|
+
switch (_context66.prev = _context66.next) {
|
|
10688
10715
|
case 0:
|
|
10689
10716
|
scheduledFor = params.scheduledFor;
|
|
10690
|
-
|
|
10717
|
+
_context66.next = 3;
|
|
10691
10718
|
return this.patch(this.baseURL + "/campaigns/".concat(id, "/schedule"), {
|
|
10692
10719
|
scheduled_for: scheduledFor
|
|
10693
10720
|
});
|
|
10694
10721
|
|
|
10695
10722
|
case 3:
|
|
10696
|
-
_yield$this$patch =
|
|
10723
|
+
_yield$this$patch = _context66.sent;
|
|
10697
10724
|
campaign = _yield$this$patch.campaign;
|
|
10698
|
-
return
|
|
10725
|
+
return _context66.abrupt("return", campaign);
|
|
10699
10726
|
|
|
10700
10727
|
case 6:
|
|
10701
10728
|
case "end":
|
|
10702
|
-
return
|
|
10729
|
+
return _context66.stop();
|
|
10703
10730
|
}
|
|
10704
10731
|
}
|
|
10705
|
-
},
|
|
10732
|
+
}, _callee66, this);
|
|
10706
10733
|
}));
|
|
10707
10734
|
|
|
10708
|
-
function scheduleCampaign(
|
|
10735
|
+
function scheduleCampaign(_x89, _x90) {
|
|
10709
10736
|
return _scheduleCampaign.apply(this, arguments);
|
|
10710
10737
|
}
|
|
10711
10738
|
|
|
@@ -10722,30 +10749,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10722
10749
|
}, {
|
|
10723
10750
|
key: "stopCampaign",
|
|
10724
10751
|
value: function () {
|
|
10725
|
-
var _stopCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10752
|
+
var _stopCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee67(id) {
|
|
10726
10753
|
var _yield$this$patch2, campaign;
|
|
10727
10754
|
|
|
10728
|
-
return _regeneratorRuntime.wrap(function
|
|
10755
|
+
return _regeneratorRuntime.wrap(function _callee67$(_context67) {
|
|
10729
10756
|
while (1) {
|
|
10730
|
-
switch (
|
|
10757
|
+
switch (_context67.prev = _context67.next) {
|
|
10731
10758
|
case 0:
|
|
10732
|
-
|
|
10759
|
+
_context67.next = 2;
|
|
10733
10760
|
return this.patch(this.baseURL + "/campaigns/".concat(id, "/stop"));
|
|
10734
10761
|
|
|
10735
10762
|
case 2:
|
|
10736
|
-
_yield$this$patch2 =
|
|
10763
|
+
_yield$this$patch2 = _context67.sent;
|
|
10737
10764
|
campaign = _yield$this$patch2.campaign;
|
|
10738
|
-
return
|
|
10765
|
+
return _context67.abrupt("return", campaign);
|
|
10739
10766
|
|
|
10740
10767
|
case 5:
|
|
10741
10768
|
case "end":
|
|
10742
|
-
return
|
|
10769
|
+
return _context67.stop();
|
|
10743
10770
|
}
|
|
10744
10771
|
}
|
|
10745
|
-
},
|
|
10772
|
+
}, _callee67, this);
|
|
10746
10773
|
}));
|
|
10747
10774
|
|
|
10748
|
-
function stopCampaign(
|
|
10775
|
+
function stopCampaign(_x91) {
|
|
10749
10776
|
return _stopCampaign.apply(this, arguments);
|
|
10750
10777
|
}
|
|
10751
10778
|
|
|
@@ -10762,30 +10789,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10762
10789
|
}, {
|
|
10763
10790
|
key: "resumeCampaign",
|
|
10764
10791
|
value: function () {
|
|
10765
|
-
var _resumeCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10792
|
+
var _resumeCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee68(id) {
|
|
10766
10793
|
var _yield$this$patch3, campaign;
|
|
10767
10794
|
|
|
10768
|
-
return _regeneratorRuntime.wrap(function
|
|
10795
|
+
return _regeneratorRuntime.wrap(function _callee68$(_context68) {
|
|
10769
10796
|
while (1) {
|
|
10770
|
-
switch (
|
|
10797
|
+
switch (_context68.prev = _context68.next) {
|
|
10771
10798
|
case 0:
|
|
10772
|
-
|
|
10799
|
+
_context68.next = 2;
|
|
10773
10800
|
return this.patch(this.baseURL + "/campaigns/".concat(id, "/resume"));
|
|
10774
10801
|
|
|
10775
10802
|
case 2:
|
|
10776
|
-
_yield$this$patch3 =
|
|
10803
|
+
_yield$this$patch3 = _context68.sent;
|
|
10777
10804
|
campaign = _yield$this$patch3.campaign;
|
|
10778
|
-
return
|
|
10805
|
+
return _context68.abrupt("return", campaign);
|
|
10779
10806
|
|
|
10780
10807
|
case 5:
|
|
10781
10808
|
case "end":
|
|
10782
|
-
return
|
|
10809
|
+
return _context68.stop();
|
|
10783
10810
|
}
|
|
10784
10811
|
}
|
|
10785
|
-
},
|
|
10812
|
+
}, _callee68, this);
|
|
10786
10813
|
}));
|
|
10787
10814
|
|
|
10788
|
-
function resumeCampaign(
|
|
10815
|
+
function resumeCampaign(_x92) {
|
|
10789
10816
|
return _resumeCampaign.apply(this, arguments);
|
|
10790
10817
|
}
|
|
10791
10818
|
|
|
@@ -10803,30 +10830,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10803
10830
|
}, {
|
|
10804
10831
|
key: "testCampaign",
|
|
10805
10832
|
value: function () {
|
|
10806
|
-
var _testCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10833
|
+
var _testCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee69(id, params) {
|
|
10807
10834
|
var users;
|
|
10808
|
-
return _regeneratorRuntime.wrap(function
|
|
10835
|
+
return _regeneratorRuntime.wrap(function _callee69$(_context69) {
|
|
10809
10836
|
while (1) {
|
|
10810
|
-
switch (
|
|
10837
|
+
switch (_context69.prev = _context69.next) {
|
|
10811
10838
|
case 0:
|
|
10812
10839
|
users = params.users;
|
|
10813
|
-
|
|
10840
|
+
_context69.next = 3;
|
|
10814
10841
|
return this.post(this.baseURL + "/campaigns/".concat(id, "/test"), {
|
|
10815
10842
|
users: users
|
|
10816
10843
|
});
|
|
10817
10844
|
|
|
10818
10845
|
case 3:
|
|
10819
|
-
return
|
|
10846
|
+
return _context69.abrupt("return", _context69.sent);
|
|
10820
10847
|
|
|
10821
10848
|
case 4:
|
|
10822
10849
|
case "end":
|
|
10823
|
-
return
|
|
10850
|
+
return _context69.stop();
|
|
10824
10851
|
}
|
|
10825
10852
|
}
|
|
10826
|
-
},
|
|
10853
|
+
}, _callee69, this);
|
|
10827
10854
|
}));
|
|
10828
10855
|
|
|
10829
|
-
function testCampaign(
|
|
10856
|
+
function testCampaign(_x93, _x94) {
|
|
10830
10857
|
return _testCampaign.apply(this, arguments);
|
|
10831
10858
|
}
|
|
10832
10859
|
|
|
@@ -10842,15 +10869,15 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10842
10869
|
}, {
|
|
10843
10870
|
key: "queryRecipients",
|
|
10844
10871
|
value: function () {
|
|
10845
|
-
var _queryRecipients = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10872
|
+
var _queryRecipients = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee70(filters) {
|
|
10846
10873
|
var options,
|
|
10847
|
-
|
|
10848
|
-
return _regeneratorRuntime.wrap(function
|
|
10874
|
+
_args70 = arguments;
|
|
10875
|
+
return _regeneratorRuntime.wrap(function _callee70$(_context70) {
|
|
10849
10876
|
while (1) {
|
|
10850
|
-
switch (
|
|
10877
|
+
switch (_context70.prev = _context70.next) {
|
|
10851
10878
|
case 0:
|
|
10852
|
-
options =
|
|
10853
|
-
|
|
10879
|
+
options = _args70.length > 1 && _args70[1] !== undefined ? _args70[1] : {};
|
|
10880
|
+
_context70.next = 3;
|
|
10854
10881
|
return this.get(this.baseURL + "/recipients", {
|
|
10855
10882
|
payload: _objectSpread({
|
|
10856
10883
|
filter_conditions: filters
|
|
@@ -10858,17 +10885,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10858
10885
|
});
|
|
10859
10886
|
|
|
10860
10887
|
case 3:
|
|
10861
|
-
return
|
|
10888
|
+
return _context70.abrupt("return", _context70.sent);
|
|
10862
10889
|
|
|
10863
10890
|
case 4:
|
|
10864
10891
|
case "end":
|
|
10865
|
-
return
|
|
10892
|
+
return _context70.stop();
|
|
10866
10893
|
}
|
|
10867
10894
|
}
|
|
10868
|
-
},
|
|
10895
|
+
}, _callee70, this);
|
|
10869
10896
|
}));
|
|
10870
10897
|
|
|
10871
|
-
function queryRecipients(
|
|
10898
|
+
function queryRecipients(_x95) {
|
|
10872
10899
|
return _queryRecipients.apply(this, arguments);
|
|
10873
10900
|
}
|
|
10874
10901
|
|
|
@@ -10884,24 +10911,24 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10884
10911
|
}, {
|
|
10885
10912
|
key: "enrichURL",
|
|
10886
10913
|
value: function () {
|
|
10887
|
-
var _enrichURL = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10888
|
-
return _regeneratorRuntime.wrap(function
|
|
10914
|
+
var _enrichURL = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee71(url) {
|
|
10915
|
+
return _regeneratorRuntime.wrap(function _callee71$(_context71) {
|
|
10889
10916
|
while (1) {
|
|
10890
|
-
switch (
|
|
10917
|
+
switch (_context71.prev = _context71.next) {
|
|
10891
10918
|
case 0:
|
|
10892
|
-
return
|
|
10919
|
+
return _context71.abrupt("return", this.get(this.baseURL + "/og", {
|
|
10893
10920
|
url: url
|
|
10894
10921
|
}));
|
|
10895
10922
|
|
|
10896
10923
|
case 1:
|
|
10897
10924
|
case "end":
|
|
10898
|
-
return
|
|
10925
|
+
return _context71.stop();
|
|
10899
10926
|
}
|
|
10900
10927
|
}
|
|
10901
|
-
},
|
|
10928
|
+
}, _callee71, this);
|
|
10902
10929
|
}));
|
|
10903
10930
|
|
|
10904
|
-
function enrichURL(
|
|
10931
|
+
function enrichURL(_x96) {
|
|
10905
10932
|
return _enrichURL.apply(this, arguments);
|
|
10906
10933
|
}
|
|
10907
10934
|
|
|
@@ -10918,22 +10945,22 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10918
10945
|
}, {
|
|
10919
10946
|
key: "getTask",
|
|
10920
10947
|
value: function () {
|
|
10921
|
-
var _getTask = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10922
|
-
return _regeneratorRuntime.wrap(function
|
|
10948
|
+
var _getTask = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee72(id) {
|
|
10949
|
+
return _regeneratorRuntime.wrap(function _callee72$(_context72) {
|
|
10923
10950
|
while (1) {
|
|
10924
|
-
switch (
|
|
10951
|
+
switch (_context72.prev = _context72.next) {
|
|
10925
10952
|
case 0:
|
|
10926
|
-
return
|
|
10953
|
+
return _context72.abrupt("return", this.get("".concat(this.baseURL, "/tasks/").concat(id)));
|
|
10927
10954
|
|
|
10928
10955
|
case 1:
|
|
10929
10956
|
case "end":
|
|
10930
|
-
return
|
|
10957
|
+
return _context72.stop();
|
|
10931
10958
|
}
|
|
10932
10959
|
}
|
|
10933
|
-
},
|
|
10960
|
+
}, _callee72, this);
|
|
10934
10961
|
}));
|
|
10935
10962
|
|
|
10936
|
-
function getTask(
|
|
10963
|
+
function getTask(_x97) {
|
|
10937
10964
|
return _getTask.apply(this, arguments);
|
|
10938
10965
|
}
|
|
10939
10966
|
|
|
@@ -10951,31 +10978,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10951
10978
|
}, {
|
|
10952
10979
|
key: "deleteChannels",
|
|
10953
10980
|
value: function () {
|
|
10954
|
-
var _deleteChannels = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10981
|
+
var _deleteChannels = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee73(cids) {
|
|
10955
10982
|
var options,
|
|
10956
|
-
|
|
10957
|
-
return _regeneratorRuntime.wrap(function
|
|
10983
|
+
_args73 = arguments;
|
|
10984
|
+
return _regeneratorRuntime.wrap(function _callee73$(_context73) {
|
|
10958
10985
|
while (1) {
|
|
10959
|
-
switch (
|
|
10986
|
+
switch (_context73.prev = _context73.next) {
|
|
10960
10987
|
case 0:
|
|
10961
|
-
options =
|
|
10962
|
-
|
|
10988
|
+
options = _args73.length > 1 && _args73[1] !== undefined ? _args73[1] : {};
|
|
10989
|
+
_context73.next = 3;
|
|
10963
10990
|
return this.post(this.baseURL + "/channels/delete", _objectSpread({
|
|
10964
10991
|
cids: cids
|
|
10965
10992
|
}, options));
|
|
10966
10993
|
|
|
10967
10994
|
case 3:
|
|
10968
|
-
return
|
|
10995
|
+
return _context73.abrupt("return", _context73.sent);
|
|
10969
10996
|
|
|
10970
10997
|
case 4:
|
|
10971
10998
|
case "end":
|
|
10972
|
-
return
|
|
10999
|
+
return _context73.stop();
|
|
10973
11000
|
}
|
|
10974
11001
|
}
|
|
10975
|
-
},
|
|
11002
|
+
}, _callee73, this);
|
|
10976
11003
|
}));
|
|
10977
11004
|
|
|
10978
|
-
function deleteChannels(
|
|
11005
|
+
function deleteChannels(_x98) {
|
|
10979
11006
|
return _deleteChannels.apply(this, arguments);
|
|
10980
11007
|
}
|
|
10981
11008
|
|
|
@@ -10993,13 +11020,13 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10993
11020
|
}, {
|
|
10994
11021
|
key: "deleteUsers",
|
|
10995
11022
|
value: function () {
|
|
10996
|
-
var _deleteUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10997
|
-
return _regeneratorRuntime.wrap(function
|
|
11023
|
+
var _deleteUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee74(user_ids, options) {
|
|
11024
|
+
return _regeneratorRuntime.wrap(function _callee74$(_context74) {
|
|
10998
11025
|
while (1) {
|
|
10999
|
-
switch (
|
|
11026
|
+
switch (_context74.prev = _context74.next) {
|
|
11000
11027
|
case 0:
|
|
11001
11028
|
if (!((options === null || options === void 0 ? void 0 : options.user) !== 'soft' && (options === null || options === void 0 ? void 0 : options.user) !== 'hard')) {
|
|
11002
|
-
|
|
11029
|
+
_context74.next = 2;
|
|
11003
11030
|
break;
|
|
11004
11031
|
}
|
|
11005
11032
|
|
|
@@ -11007,7 +11034,7 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11007
11034
|
|
|
11008
11035
|
case 2:
|
|
11009
11036
|
if (!(options.messages !== undefined && options.messages !== 'soft' && options.messages !== 'hard')) {
|
|
11010
|
-
|
|
11037
|
+
_context74.next = 4;
|
|
11011
11038
|
break;
|
|
11012
11039
|
}
|
|
11013
11040
|
|
|
@@ -11015,30 +11042,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11015
11042
|
|
|
11016
11043
|
case 4:
|
|
11017
11044
|
if (!(options.conversations !== undefined && options.conversations !== 'soft' && options.conversations !== 'hard')) {
|
|
11018
|
-
|
|
11045
|
+
_context74.next = 6;
|
|
11019
11046
|
break;
|
|
11020
11047
|
}
|
|
11021
11048
|
|
|
11022
11049
|
throw new Error('Invalid delete user options. conversations must be one of [soft hard]');
|
|
11023
11050
|
|
|
11024
11051
|
case 6:
|
|
11025
|
-
|
|
11052
|
+
_context74.next = 8;
|
|
11026
11053
|
return this.post(this.baseURL + "/users/delete", _objectSpread({
|
|
11027
11054
|
user_ids: user_ids
|
|
11028
11055
|
}, options));
|
|
11029
11056
|
|
|
11030
11057
|
case 8:
|
|
11031
|
-
return
|
|
11058
|
+
return _context74.abrupt("return", _context74.sent);
|
|
11032
11059
|
|
|
11033
11060
|
case 9:
|
|
11034
11061
|
case "end":
|
|
11035
|
-
return
|
|
11062
|
+
return _context74.stop();
|
|
11036
11063
|
}
|
|
11037
11064
|
}
|
|
11038
|
-
},
|
|
11065
|
+
}, _callee74, this);
|
|
11039
11066
|
}));
|
|
11040
11067
|
|
|
11041
|
-
function deleteUsers(
|
|
11068
|
+
function deleteUsers(_x99, _x100) {
|
|
11042
11069
|
return _deleteUsers.apply(this, arguments);
|
|
11043
11070
|
}
|
|
11044
11071
|
|
|
@@ -11059,28 +11086,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11059
11086
|
}, {
|
|
11060
11087
|
key: "_createImportURL",
|
|
11061
11088
|
value: function () {
|
|
11062
|
-
var _createImportURL2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11063
|
-
return _regeneratorRuntime.wrap(function
|
|
11089
|
+
var _createImportURL2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee75(filename) {
|
|
11090
|
+
return _regeneratorRuntime.wrap(function _callee75$(_context75) {
|
|
11064
11091
|
while (1) {
|
|
11065
|
-
switch (
|
|
11092
|
+
switch (_context75.prev = _context75.next) {
|
|
11066
11093
|
case 0:
|
|
11067
|
-
|
|
11094
|
+
_context75.next = 2;
|
|
11068
11095
|
return this.post(this.baseURL + "/import_urls", {
|
|
11069
11096
|
filename: filename
|
|
11070
11097
|
});
|
|
11071
11098
|
|
|
11072
11099
|
case 2:
|
|
11073
|
-
return
|
|
11100
|
+
return _context75.abrupt("return", _context75.sent);
|
|
11074
11101
|
|
|
11075
11102
|
case 3:
|
|
11076
11103
|
case "end":
|
|
11077
|
-
return
|
|
11104
|
+
return _context75.stop();
|
|
11078
11105
|
}
|
|
11079
11106
|
}
|
|
11080
|
-
},
|
|
11107
|
+
}, _callee75, this);
|
|
11081
11108
|
}));
|
|
11082
11109
|
|
|
11083
|
-
function _createImportURL(
|
|
11110
|
+
function _createImportURL(_x101) {
|
|
11084
11111
|
return _createImportURL2.apply(this, arguments);
|
|
11085
11112
|
}
|
|
11086
11113
|
|
|
@@ -11102,33 +11129,33 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11102
11129
|
}, {
|
|
11103
11130
|
key: "_createImport",
|
|
11104
11131
|
value: function () {
|
|
11105
|
-
var _createImport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11132
|
+
var _createImport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee76(path) {
|
|
11106
11133
|
var options,
|
|
11107
|
-
|
|
11108
|
-
return _regeneratorRuntime.wrap(function
|
|
11134
|
+
_args76 = arguments;
|
|
11135
|
+
return _regeneratorRuntime.wrap(function _callee76$(_context76) {
|
|
11109
11136
|
while (1) {
|
|
11110
|
-
switch (
|
|
11137
|
+
switch (_context76.prev = _context76.next) {
|
|
11111
11138
|
case 0:
|
|
11112
|
-
options =
|
|
11139
|
+
options = _args76.length > 1 && _args76[1] !== undefined ? _args76[1] : {
|
|
11113
11140
|
mode: 'upsert'
|
|
11114
11141
|
};
|
|
11115
|
-
|
|
11142
|
+
_context76.next = 3;
|
|
11116
11143
|
return this.post(this.baseURL + "/imports", _objectSpread({
|
|
11117
11144
|
path: path
|
|
11118
11145
|
}, options));
|
|
11119
11146
|
|
|
11120
11147
|
case 3:
|
|
11121
|
-
return
|
|
11148
|
+
return _context76.abrupt("return", _context76.sent);
|
|
11122
11149
|
|
|
11123
11150
|
case 4:
|
|
11124
11151
|
case "end":
|
|
11125
|
-
return
|
|
11152
|
+
return _context76.stop();
|
|
11126
11153
|
}
|
|
11127
11154
|
}
|
|
11128
|
-
},
|
|
11155
|
+
}, _callee76, this);
|
|
11129
11156
|
}));
|
|
11130
11157
|
|
|
11131
|
-
function _createImport(
|
|
11158
|
+
function _createImport(_x102) {
|
|
11132
11159
|
return _createImport2.apply(this, arguments);
|
|
11133
11160
|
}
|
|
11134
11161
|
|
|
@@ -11150,26 +11177,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11150
11177
|
}, {
|
|
11151
11178
|
key: "_getImport",
|
|
11152
11179
|
value: function () {
|
|
11153
|
-
var _getImport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11154
|
-
return _regeneratorRuntime.wrap(function
|
|
11180
|
+
var _getImport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee77(id) {
|
|
11181
|
+
return _regeneratorRuntime.wrap(function _callee77$(_context77) {
|
|
11155
11182
|
while (1) {
|
|
11156
|
-
switch (
|
|
11183
|
+
switch (_context77.prev = _context77.next) {
|
|
11157
11184
|
case 0:
|
|
11158
|
-
|
|
11185
|
+
_context77.next = 2;
|
|
11159
11186
|
return this.get(this.baseURL + "/imports/".concat(id));
|
|
11160
11187
|
|
|
11161
11188
|
case 2:
|
|
11162
|
-
return
|
|
11189
|
+
return _context77.abrupt("return", _context77.sent);
|
|
11163
11190
|
|
|
11164
11191
|
case 3:
|
|
11165
11192
|
case "end":
|
|
11166
|
-
return
|
|
11193
|
+
return _context77.stop();
|
|
11167
11194
|
}
|
|
11168
11195
|
}
|
|
11169
|
-
},
|
|
11196
|
+
}, _callee77, this);
|
|
11170
11197
|
}));
|
|
11171
11198
|
|
|
11172
|
-
function _getImport(
|
|
11199
|
+
function _getImport(_x103) {
|
|
11173
11200
|
return _getImport2.apply(this, arguments);
|
|
11174
11201
|
}
|
|
11175
11202
|
|
|
@@ -11191,26 +11218,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11191
11218
|
}, {
|
|
11192
11219
|
key: "_listImports",
|
|
11193
11220
|
value: function () {
|
|
11194
|
-
var _listImports2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11195
|
-
return _regeneratorRuntime.wrap(function
|
|
11221
|
+
var _listImports2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee78(options) {
|
|
11222
|
+
return _regeneratorRuntime.wrap(function _callee78$(_context78) {
|
|
11196
11223
|
while (1) {
|
|
11197
|
-
switch (
|
|
11224
|
+
switch (_context78.prev = _context78.next) {
|
|
11198
11225
|
case 0:
|
|
11199
|
-
|
|
11226
|
+
_context78.next = 2;
|
|
11200
11227
|
return this.get(this.baseURL + "/imports", options);
|
|
11201
11228
|
|
|
11202
11229
|
case 2:
|
|
11203
|
-
return
|
|
11230
|
+
return _context78.abrupt("return", _context78.sent);
|
|
11204
11231
|
|
|
11205
11232
|
case 3:
|
|
11206
11233
|
case "end":
|
|
11207
|
-
return
|
|
11234
|
+
return _context78.stop();
|
|
11208
11235
|
}
|
|
11209
11236
|
}
|
|
11210
|
-
},
|
|
11237
|
+
}, _callee78, this);
|
|
11211
11238
|
}));
|
|
11212
11239
|
|
|
11213
|
-
function _listImports(
|
|
11240
|
+
function _listImports(_x104) {
|
|
11214
11241
|
return _listImports2.apply(this, arguments);
|
|
11215
11242
|
}
|
|
11216
11243
|
|
|
@@ -11229,28 +11256,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11229
11256
|
}, {
|
|
11230
11257
|
key: "upsertPushProvider",
|
|
11231
11258
|
value: function () {
|
|
11232
|
-
var _upsertPushProvider = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11233
|
-
return _regeneratorRuntime.wrap(function
|
|
11259
|
+
var _upsertPushProvider = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee79(pushProvider) {
|
|
11260
|
+
return _regeneratorRuntime.wrap(function _callee79$(_context79) {
|
|
11234
11261
|
while (1) {
|
|
11235
|
-
switch (
|
|
11262
|
+
switch (_context79.prev = _context79.next) {
|
|
11236
11263
|
case 0:
|
|
11237
|
-
|
|
11264
|
+
_context79.next = 2;
|
|
11238
11265
|
return this.post(this.baseURL + "/push_providers", {
|
|
11239
11266
|
push_provider: pushProvider
|
|
11240
11267
|
});
|
|
11241
11268
|
|
|
11242
11269
|
case 2:
|
|
11243
|
-
return
|
|
11270
|
+
return _context79.abrupt("return", _context79.sent);
|
|
11244
11271
|
|
|
11245
11272
|
case 3:
|
|
11246
11273
|
case "end":
|
|
11247
|
-
return
|
|
11274
|
+
return _context79.stop();
|
|
11248
11275
|
}
|
|
11249
11276
|
}
|
|
11250
|
-
},
|
|
11277
|
+
}, _callee79, this);
|
|
11251
11278
|
}));
|
|
11252
11279
|
|
|
11253
|
-
function upsertPushProvider(
|
|
11280
|
+
function upsertPushProvider(_x105) {
|
|
11254
11281
|
return _upsertPushProvider.apply(this, arguments);
|
|
11255
11282
|
}
|
|
11256
11283
|
|
|
@@ -11269,28 +11296,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11269
11296
|
}, {
|
|
11270
11297
|
key: "deletePushProvider",
|
|
11271
11298
|
value: function () {
|
|
11272
|
-
var _deletePushProvider = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11299
|
+
var _deletePushProvider = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee80(_ref10) {
|
|
11273
11300
|
var type, name;
|
|
11274
|
-
return _regeneratorRuntime.wrap(function
|
|
11301
|
+
return _regeneratorRuntime.wrap(function _callee80$(_context80) {
|
|
11275
11302
|
while (1) {
|
|
11276
|
-
switch (
|
|
11303
|
+
switch (_context80.prev = _context80.next) {
|
|
11277
11304
|
case 0:
|
|
11278
11305
|
type = _ref10.type, name = _ref10.name;
|
|
11279
|
-
|
|
11306
|
+
_context80.next = 3;
|
|
11280
11307
|
return this.delete(this.baseURL + "/push_providers/".concat(type, "/").concat(name));
|
|
11281
11308
|
|
|
11282
11309
|
case 3:
|
|
11283
|
-
return
|
|
11310
|
+
return _context80.abrupt("return", _context80.sent);
|
|
11284
11311
|
|
|
11285
11312
|
case 4:
|
|
11286
11313
|
case "end":
|
|
11287
|
-
return
|
|
11314
|
+
return _context80.stop();
|
|
11288
11315
|
}
|
|
11289
11316
|
}
|
|
11290
|
-
},
|
|
11317
|
+
}, _callee80, this);
|
|
11291
11318
|
}));
|
|
11292
11319
|
|
|
11293
|
-
function deletePushProvider(
|
|
11320
|
+
function deletePushProvider(_x106) {
|
|
11294
11321
|
return _deletePushProvider.apply(this, arguments);
|
|
11295
11322
|
}
|
|
11296
11323
|
|
|
@@ -11307,23 +11334,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11307
11334
|
}, {
|
|
11308
11335
|
key: "listPushProviders",
|
|
11309
11336
|
value: function () {
|
|
11310
|
-
var _listPushProviders = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11311
|
-
return _regeneratorRuntime.wrap(function
|
|
11337
|
+
var _listPushProviders = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee81() {
|
|
11338
|
+
return _regeneratorRuntime.wrap(function _callee81$(_context81) {
|
|
11312
11339
|
while (1) {
|
|
11313
|
-
switch (
|
|
11340
|
+
switch (_context81.prev = _context81.next) {
|
|
11314
11341
|
case 0:
|
|
11315
|
-
|
|
11342
|
+
_context81.next = 2;
|
|
11316
11343
|
return this.get(this.baseURL + "/push_providers");
|
|
11317
11344
|
|
|
11318
11345
|
case 2:
|
|
11319
|
-
return
|
|
11346
|
+
return _context81.abrupt("return", _context81.sent);
|
|
11320
11347
|
|
|
11321
11348
|
case 3:
|
|
11322
11349
|
case "end":
|
|
11323
|
-
return
|
|
11350
|
+
return _context81.stop();
|
|
11324
11351
|
}
|
|
11325
11352
|
}
|
|
11326
|
-
},
|
|
11353
|
+
}, _callee81, this);
|
|
11327
11354
|
}));
|
|
11328
11355
|
|
|
11329
11356
|
function listPushProviders() {
|
|
@@ -11351,26 +11378,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11351
11378
|
}, {
|
|
11352
11379
|
key: "commitMessage",
|
|
11353
11380
|
value: function () {
|
|
11354
|
-
var _commitMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11355
|
-
return _regeneratorRuntime.wrap(function
|
|
11381
|
+
var _commitMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee82(id) {
|
|
11382
|
+
return _regeneratorRuntime.wrap(function _callee82$(_context82) {
|
|
11356
11383
|
while (1) {
|
|
11357
|
-
switch (
|
|
11384
|
+
switch (_context82.prev = _context82.next) {
|
|
11358
11385
|
case 0:
|
|
11359
|
-
|
|
11386
|
+
_context82.next = 2;
|
|
11360
11387
|
return this.post(this.baseURL + "/messages/".concat(id, "/commit"));
|
|
11361
11388
|
|
|
11362
11389
|
case 2:
|
|
11363
|
-
return
|
|
11390
|
+
return _context82.abrupt("return", _context82.sent);
|
|
11364
11391
|
|
|
11365
11392
|
case 3:
|
|
11366
11393
|
case "end":
|
|
11367
|
-
return
|
|
11394
|
+
return _context82.stop();
|
|
11368
11395
|
}
|
|
11369
11396
|
}
|
|
11370
|
-
},
|
|
11397
|
+
}, _callee82, this);
|
|
11371
11398
|
}));
|
|
11372
11399
|
|
|
11373
|
-
function commitMessage(
|
|
11400
|
+
function commitMessage(_x107) {
|
|
11374
11401
|
return _commitMessage.apply(this, arguments);
|
|
11375
11402
|
}
|
|
11376
11403
|
|