@webex/internal-plugin-conversation 3.7.0 → 3.8.0-next.2

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.
@@ -282,17 +282,18 @@ var Conversation = _webexCore.WebexPlugin.extend({
282
282
  });
283
283
  },
284
284
  /**
285
- * delete a reaction
286
- * @param {Object} conversation
287
- * @param {Object} reactionId,
288
- * @param {String} recipientId,
285
+ * create a reaction
286
+ * @param {Object} conversation the conversation in which the reaction will be added
287
+ * @param {Object} reactionId reaction activity to be deleted
288
+ * @param {Object} actorId id of person object who is reacting
289
+ * @param {String} recipientId used when reacting to direct IMC messages
289
290
  * @returns {Promise<Activity>}
290
291
  */
291
- deleteReaction: function deleteReaction(conversation, reactionId, recipientId) {
292
+ deleteReaction: function deleteReaction(conversation, reactionId, actorId, recipientId) {
292
293
  var deleteReactionPayload = {
293
294
  actor: {
294
295
  objectType: 'person',
295
- id: this.webex.internal.device.userId
296
+ id: actorId !== null && actorId !== void 0 ? actorId : this.webex.internal.device.userId
296
297
  },
297
298
  object: {
298
299
  id: reactionId,
@@ -319,46 +320,65 @@ var Conversation = _webexCore.WebexPlugin.extend({
319
320
  },
320
321
  /**
321
322
  * create a reaction
322
- * @param {Object} conversation
323
+ * @param {Object} conversation the conversation in which the reaction will be added
323
324
  * @param {Object} displayName must be 'celebrate', 'heart', 'thumbsup', 'smiley', 'haha', 'confused', 'sad'
324
- * @param {Object} activity activity object from convo we are reacting to
325
- * @param {String} recipientId,
325
+ * @param {Object} parentActivity activity object from that we are reacting to
326
+ * @param {Object} actorId id of person object who is reacting
327
+ * @param {String} recipientId used when reacting to direct IMC messages
326
328
  * @returns {Promise<Activity>}
327
329
  */
328
- addReaction: function addReaction(conversation, displayName, activity, recipientId) {
330
+ addReaction: function addReaction(conversation, displayName, parentActivity, actorId, recipientId) {
329
331
  var _this7 = this;
330
- return this.createReactionHmac(displayName, activity).then(function (hmac) {
331
- var addReactionPayload = {
332
- actor: {
333
- objectType: 'person',
334
- id: _this7.webex.internal.device.userId
335
- },
336
- target: {
337
- id: conversation.id,
338
- objectType: 'conversation'
339
- },
340
- verb: 'add',
341
- objectType: 'activity',
342
- parent: {
343
- type: 'reaction',
344
- id: activity.id
345
- },
346
- object: {
347
- objectType: 'reaction2',
348
- displayName: displayName,
349
- hmac: hmac
332
+ return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee() {
333
+ var hmac, addReactionPayload;
334
+ return _regenerator.default.wrap(function _callee$(_context) {
335
+ while (1) switch (_context.prev = _context.next) {
336
+ case 0:
337
+ if (!_this7.config.includeEncryptionTransforms) {
338
+ _context.next = 4;
339
+ break;
340
+ }
341
+ _context.next = 3;
342
+ return _this7.createReactionHmac(displayName, parentActivity);
343
+ case 3:
344
+ hmac = _context.sent;
345
+ case 4:
346
+ addReactionPayload = {
347
+ actor: {
348
+ objectType: 'person',
349
+ id: actorId !== null && actorId !== void 0 ? actorId : _this7.webex.internal.device.userId
350
+ },
351
+ target: {
352
+ id: conversation.id,
353
+ objectType: 'conversation'
354
+ },
355
+ verb: 'add',
356
+ objectType: 'activity',
357
+ parent: {
358
+ type: 'reaction',
359
+ id: parentActivity.id
360
+ },
361
+ object: {
362
+ objectType: 'reaction2',
363
+ displayName: displayName,
364
+ hmac: hmac
365
+ }
366
+ };
367
+ if (recipientId) {
368
+ addReactionPayload.recipients = {
369
+ items: [{
370
+ id: recipientId,
371
+ objectType: 'person'
372
+ }]
373
+ };
374
+ }
375
+ return _context.abrupt("return", _this7.sendReaction(conversation, addReactionPayload));
376
+ case 7:
377
+ case "end":
378
+ return _context.stop();
350
379
  }
351
- };
352
- if (recipientId) {
353
- addReactionPayload.recipients = {
354
- items: [{
355
- id: recipientId,
356
- objectType: 'person'
357
- }]
358
- };
359
- }
360
- return _this7.sendReaction(conversation, addReactionPayload);
361
- });
380
+ }, _callee);
381
+ }))();
362
382
  },
363
383
  /**
364
384
  * delete content
@@ -694,23 +714,23 @@ var Conversation = _webexCore.WebexPlugin.extend({
694
714
  paginate: function paginate() {
695
715
  var _arguments = arguments,
696
716
  _this12 = this;
697
- return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee() {
717
+ return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee2() {
698
718
  var options, queryOptions, reqOptions;
699
- return _regenerator.default.wrap(function _callee$(_context) {
700
- while (1) switch (_context.prev = _context.next) {
719
+ return _regenerator.default.wrap(function _callee2$(_context2) {
720
+ while (1) switch (_context2.prev = _context2.next) {
701
721
  case 0:
702
722
  options = _arguments.length > 0 && _arguments[0] !== undefined ? _arguments[0] : {};
703
723
  if (!options.page) {
704
- _context.next = 5;
724
+ _context2.next = 5;
705
725
  break;
706
726
  }
707
727
  if (!(!options.page.links || !options.page.links.next)) {
708
- _context.next = 4;
728
+ _context2.next = 4;
709
729
  break;
710
730
  }
711
731
  throw new Error('No link to follow for the provided page');
712
732
  case 4:
713
- return _context.abrupt("return", _this12.request({
733
+ return _context2.abrupt("return", _this12.request({
714
734
  url: options.page.links.next
715
735
  }).then(function (res) {
716
736
  return {
@@ -738,7 +758,7 @@ var Conversation = _webexCore.WebexPlugin.extend({
738
758
  reqOptions.service = 'conversation';
739
759
  reqOptions.resource = 'conversations';
740
760
  }
741
- return _context.abrupt("return", _this12.request(reqOptions).then(function (res) {
761
+ return _context2.abrupt("return", _this12.request(reqOptions).then(function (res) {
742
762
  var response = {
743
763
  page: new _webexCore.Page(res, _this12.webex)
744
764
  };
@@ -749,9 +769,9 @@ var Conversation = _webexCore.WebexPlugin.extend({
749
769
  }));
750
770
  case 9:
751
771
  case "end":
752
- return _context.stop();
772
+ return _context2.stop();
753
773
  }
754
- }, _callee);
774
+ }, _callee2);
755
775
  }))();
756
776
  },
757
777
  /**
@@ -812,26 +832,26 @@ var Conversation = _webexCore.WebexPlugin.extend({
812
832
  */
813
833
  listParentActivityIds: function listParentActivityIds(conversationUrl, query) {
814
834
  var _this13 = this;
815
- return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee2() {
835
+ return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee3() {
816
836
  var params, response;
817
- return _regenerator.default.wrap(function _callee2$(_context2) {
818
- while (1) switch (_context2.prev = _context2.next) {
837
+ return _regenerator.default.wrap(function _callee3$(_context3) {
838
+ while (1) switch (_context3.prev = _context3.next) {
819
839
  case 0:
820
840
  params = {
821
841
  method: 'GET',
822
842
  url: "".concat(conversationUrl, "/parents"),
823
843
  qs: query
824
844
  };
825
- _context2.next = 3;
845
+ _context3.next = 3;
826
846
  return _this13.request(params);
827
847
  case 3:
828
- response = _context2.sent;
829
- return _context2.abrupt("return", response.body);
848
+ response = _context3.sent;
849
+ return _context3.abrupt("return", response.body);
830
850
  case 5:
831
851
  case "end":
832
- return _context2.stop();
852
+ return _context3.stop();
833
853
  }
834
- }, _callee2);
854
+ }, _callee3);
835
855
  }))();
836
856
  },
837
857
  /**
@@ -845,29 +865,29 @@ var Conversation = _webexCore.WebexPlugin.extend({
845
865
  listAllChildActivitiesByParentId: function listAllChildActivitiesByParentId() {
846
866
  var _arguments2 = arguments,
847
867
  _this14 = this;
848
- return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee3() {
868
+ return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee4() {
849
869
  var options, conversationUrl, activityParentId, query, activityType, initialResponse, page, items, _iterator3, _step3, activity;
850
- return _regenerator.default.wrap(function _callee3$(_context3) {
851
- while (1) switch (_context3.prev = _context3.next) {
870
+ return _regenerator.default.wrap(function _callee4$(_context4) {
871
+ while (1) switch (_context4.prev = _context4.next) {
852
872
  case 0:
853
873
  options = _arguments2.length > 0 && _arguments2[0] !== undefined ? _arguments2[0] : {};
854
874
  conversationUrl = options.conversationUrl, activityParentId = options.activityParentId, query = options.query;
855
875
  activityType = query.activityType;
856
- _context3.next = 5;
876
+ _context4.next = 5;
857
877
  return _this14.listChildActivitiesByParentId(conversationUrl, activityParentId, activityType, query);
858
878
  case 5:
859
- initialResponse = _context3.sent;
879
+ initialResponse = _context4.sent;
860
880
  page = new _webexCore.Page(initialResponse, _this14.webex);
861
881
  items = (0, _toConsumableArray2.default)(page.items);
862
882
  case 8:
863
883
  if (!page.hasNext()) {
864
- _context3.next = 16;
884
+ _context4.next = 16;
865
885
  break;
866
886
  }
867
- _context3.next = 11;
887
+ _context4.next = 11;
868
888
  return page.next();
869
889
  case 11:
870
- page = _context3.sent;
890
+ page = _context4.sent;
871
891
  _iterator3 = _createForOfIteratorHelper(page);
872
892
  try {
873
893
  for (_iterator3.s(); !(_step3 = _iterator3.n()).done;) {
@@ -879,19 +899,19 @@ var Conversation = _webexCore.WebexPlugin.extend({
879
899
  } finally {
880
900
  _iterator3.f();
881
901
  }
882
- _context3.next = 8;
902
+ _context4.next = 8;
883
903
  break;
884
904
  case 16:
885
905
  // reverse list if needed (see _list for precedent)
886
906
  if (items.length && (0, _lodash.last)(items).published < items[0].published) {
887
907
  items.reverse();
888
908
  }
889
- return _context3.abrupt("return", items);
909
+ return _context4.abrupt("return", items);
890
910
  case 18:
891
911
  case "end":
892
- return _context3.stop();
912
+ return _context4.stop();
893
913
  }
894
- }, _callee3);
914
+ }, _callee4);
895
915
  }))();
896
916
  },
897
917
  /**
@@ -906,10 +926,10 @@ var Conversation = _webexCore.WebexPlugin.extend({
906
926
  listChildActivitiesByParentId: function listChildActivitiesByParentId(conversationUrl, activityParentId, activityType) {
907
927
  var _arguments3 = arguments,
908
928
  _this15 = this;
909
- return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee4() {
929
+ return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee5() {
910
930
  var query, finalQuery, params;
911
- return _regenerator.default.wrap(function _callee4$(_context4) {
912
- while (1) switch (_context4.prev = _context4.next) {
931
+ return _regenerator.default.wrap(function _callee5$(_context5) {
932
+ while (1) switch (_context5.prev = _context5.next) {
913
933
  case 0:
914
934
  query = _arguments3.length > 3 && _arguments3[3] !== undefined ? _arguments3[3] : {};
915
935
  finalQuery = _objectSpread(_objectSpread({}, query), {}, {
@@ -920,12 +940,12 @@ var Conversation = _webexCore.WebexPlugin.extend({
920
940
  url: "".concat(conversationUrl, "/parents/").concat(activityParentId),
921
941
  qs: finalQuery
922
942
  };
923
- return _context4.abrupt("return", _this15.request(params));
943
+ return _context5.abrupt("return", _this15.request(params));
924
944
  case 4:
925
945
  case "end":
926
- return _context4.stop();
946
+ return _context5.stop();
927
947
  }
928
- }, _callee4);
948
+ }, _callee5);
929
949
  }))();
930
950
  },
931
951
  /**
@@ -937,29 +957,29 @@ var Conversation = _webexCore.WebexPlugin.extend({
937
957
  */
938
958
  getReactionSummaryByParentId: function getReactionSummaryByParentId(conversationUrl, activityParentId, query) {
939
959
  var _this16 = this;
940
- return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee5() {
960
+ return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee6() {
941
961
  var _yield$_this16$reques, body, reactionObjects;
942
- return _regenerator.default.wrap(function _callee5$(_context5) {
943
- while (1) switch (_context5.prev = _context5.next) {
962
+ return _regenerator.default.wrap(function _callee6$(_context6) {
963
+ while (1) switch (_context6.prev = _context6.next) {
944
964
  case 0:
945
- _context5.next = 2;
965
+ _context6.next = 2;
946
966
  return _this16.request({
947
967
  method: 'GET',
948
968
  url: "".concat(conversationUrl, "/activities/").concat(activityParentId),
949
969
  qs: query
950
970
  });
951
971
  case 2:
952
- _yield$_this16$reques = _context5.sent;
972
+ _yield$_this16$reques = _context6.sent;
953
973
  body = _yield$_this16$reques.body;
954
974
  reactionObjects = body.children ? body.children.filter(function (child) {
955
975
  return child.type === 'reactionSelfSummary' || child.type === 'reactionSummary';
956
976
  }) : [];
957
- return _context5.abrupt("return", reactionObjects);
977
+ return _context6.abrupt("return", reactionObjects);
958
978
  case 6:
959
979
  case "end":
960
- return _context5.stop();
980
+ return _context6.stop();
961
981
  }
962
- }, _callee5);
982
+ }, _callee6);
963
983
  }))();
964
984
  },
965
985
  /**
@@ -1134,20 +1154,20 @@ var Conversation = _webexCore.WebexPlugin.extend({
1134
1154
  */
1135
1155
  listThreads: function listThreads(options) {
1136
1156
  var _this20 = this;
1137
- return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee6() {
1138
- return _regenerator.default.wrap(function _callee6$(_context6) {
1139
- while (1) switch (_context6.prev = _context6.next) {
1157
+ return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee7() {
1158
+ return _regenerator.default.wrap(function _callee7$(_context7) {
1159
+ while (1) switch (_context7.prev = _context7.next) {
1140
1160
  case 0:
1141
- return _context6.abrupt("return", _this20._list({
1161
+ return _context7.abrupt("return", _this20._list({
1142
1162
  service: 'conversation',
1143
1163
  resource: 'threads',
1144
1164
  qs: (0, _lodash.omit)(options, 'showAllTypes')
1145
1165
  }));
1146
1166
  case 1:
1147
1167
  case "end":
1148
- return _context6.stop();
1168
+ return _context7.stop();
1149
1169
  }
1150
- }, _callee6);
1170
+ }, _callee7);
1151
1171
  }))();
1152
1172
  },
1153
1173
  /**
@@ -1714,20 +1734,20 @@ var Conversation = _webexCore.WebexPlugin.extend({
1714
1734
  * @returns {IGeneratorResponse}
1715
1735
  */
1716
1736
  var jumpToActivity = /*#__PURE__*/function () {
1717
- var _ref4 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee7(searchObject) {
1737
+ var _ref4 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee8(searchObject) {
1718
1738
  var newUrl, searchOptions, _yield$threadOrderer$, searchResults;
1719
- return _regenerator.default.wrap(function _callee7$(_context7) {
1720
- while (1) switch (_context7.prev = _context7.next) {
1739
+ return _regenerator.default.wrap(function _callee8$(_context8) {
1740
+ while (1) switch (_context8.prev = _context8.next) {
1721
1741
  case 0:
1722
1742
  if (searchObject) {
1723
- _context7.next = 2;
1743
+ _context8.next = 2;
1724
1744
  break;
1725
1745
  }
1726
1746
  throw new Error('Search must be an activity object from conversation service');
1727
1747
  case 2:
1728
1748
  newUrl = searchObject.target && searchObject.target.url;
1729
1749
  if (newUrl) {
1730
- _context7.next = 5;
1750
+ _context8.next = 5;
1731
1751
  break;
1732
1752
  }
1733
1753
  throw new Error('Search object must have a target url!');
@@ -1738,20 +1758,20 @@ var Conversation = _webexCore.WebexPlugin.extend({
1738
1758
  search: searchObject
1739
1759
  });
1740
1760
  threadOrderer = _this30._listActivitiesThreadOrdered(searchOptions);
1741
- _context7.next = 9;
1761
+ _context8.next = 9;
1742
1762
  return threadOrderer.next(searchOptions);
1743
1763
  case 9:
1744
- _yield$threadOrderer$ = _context7.sent;
1764
+ _yield$threadOrderer$ = _context8.sent;
1745
1765
  searchResults = _yield$threadOrderer$.value;
1746
- return _context7.abrupt("return", {
1766
+ return _context8.abrupt("return", {
1747
1767
  done: true,
1748
1768
  value: searchResults
1749
1769
  });
1750
1770
  case 12:
1751
1771
  case "end":
1752
- return _context7.stop();
1772
+ return _context8.stop();
1753
1773
  }
1754
- }, _callee7);
1774
+ }, _callee8);
1755
1775
  }));
1756
1776
  return function jumpToActivity(_x) {
1757
1777
  return _ref4.apply(this, arguments);
@@ -1763,28 +1783,28 @@ var Conversation = _webexCore.WebexPlugin.extend({
1763
1783
  * @returns {IGeneratorResponse}
1764
1784
  */
1765
1785
  var getOlder = /*#__PURE__*/function () {
1766
- var _ref5 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee8() {
1786
+ var _ref5 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee9() {
1767
1787
  var _yield$threadOrderer$2, _yield$threadOrderer$3, value, oldestInBatch, moreActivitiesExist;
1768
- return _regenerator.default.wrap(function _callee8$(_context8) {
1769
- while (1) switch (_context8.prev = _context8.next) {
1788
+ return _regenerator.default.wrap(function _callee9$(_context9) {
1789
+ while (1) switch (_context9.prev = _context9.next) {
1770
1790
  case 0:
1771
- _context8.next = 2;
1791
+ _context9.next = 2;
1772
1792
  return threadOrderer.next(olderOptions);
1773
1793
  case 2:
1774
- _yield$threadOrderer$2 = _context8.sent;
1794
+ _yield$threadOrderer$2 = _context9.sent;
1775
1795
  _yield$threadOrderer$3 = _yield$threadOrderer$2.value;
1776
1796
  value = _yield$threadOrderer$3 === void 0 ? [] : _yield$threadOrderer$3;
1777
1797
  oldestInBatch = value[0] && value[0].activity;
1778
1798
  moreActivitiesExist = oldestInBatch && (0, _activities.getActivityType)(oldestInBatch) !== _activities.ACTIVITY_TYPES.CREATE;
1779
- return _context8.abrupt("return", {
1799
+ return _context9.abrupt("return", {
1780
1800
  done: !moreActivitiesExist,
1781
1801
  value: value
1782
1802
  });
1783
1803
  case 8:
1784
1804
  case "end":
1785
- return _context8.stop();
1805
+ return _context9.stop();
1786
1806
  }
1787
- }, _callee8);
1807
+ }, _callee9);
1788
1808
  }));
1789
1809
  return function getOlder() {
1790
1810
  return _ref5.apply(this, arguments);
@@ -1796,28 +1816,28 @@ var Conversation = _webexCore.WebexPlugin.extend({
1796
1816
  * @returns {IGeneratorResponse}
1797
1817
  */
1798
1818
  var getNewer = /*#__PURE__*/function () {
1799
- var _ref6 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee9() {
1819
+ var _ref6 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee10() {
1800
1820
  var newerOptions, _yield$threadOrderer$4, value;
1801
- return _regenerator.default.wrap(function _callee9$(_context9) {
1802
- while (1) switch (_context9.prev = _context9.next) {
1821
+ return _regenerator.default.wrap(function _callee10$(_context10) {
1822
+ while (1) switch (_context10.prev = _context10.next) {
1803
1823
  case 0:
1804
1824
  newerOptions = _objectSpread(_objectSpread({}, baseOptions), {}, {
1805
1825
  queryType: _activities.NEWER
1806
1826
  });
1807
- _context9.next = 3;
1827
+ _context10.next = 3;
1808
1828
  return threadOrderer.next(newerOptions);
1809
1829
  case 3:
1810
- _yield$threadOrderer$4 = _context9.sent;
1830
+ _yield$threadOrderer$4 = _context10.sent;
1811
1831
  value = _yield$threadOrderer$4.value;
1812
- return _context9.abrupt("return", {
1832
+ return _context10.abrupt("return", {
1813
1833
  done: !value.length,
1814
1834
  value: value
1815
1835
  });
1816
1836
  case 6:
1817
1837
  case "end":
1818
- return _context9.stop();
1838
+ return _context10.stop();
1819
1839
  }
1820
- }, _callee9);
1840
+ }, _callee10);
1821
1841
  }));
1822
1842
  return function getNewer() {
1823
1843
  return _ref6.apply(this, arguments);
@@ -1860,10 +1880,10 @@ var Conversation = _webexCore.WebexPlugin.extend({
1860
1880
  _listActivitiesThreadOrdered: function _listActivitiesThreadOrdered() {
1861
1881
  var _this = this;
1862
1882
  var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
1863
- return (0, _wrapAsyncGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee10() {
1883
+ return (0, _wrapAsyncGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee11() {
1864
1884
  var _options$minActivitie, minActivities, _options$queryType, queryType, convoUrl, _options$search, search, includeChildren, _bookendManager, setBookends, getNewestAct, getOldestAct, defaultBatchSize, batchSize, _activityManager, getActivityHandlerByKey, getActivityByTypeAndParentId, query, _loop, _ret;
1865
- return _regenerator.default.wrap(function _callee10$(_context12) {
1866
- while (1) switch (_context12.prev = _context12.next) {
1885
+ return _regenerator.default.wrap(function _callee11$(_context13) {
1886
+ while (1) switch (_context13.prev = _context13.next) {
1867
1887
  case 0:
1868
1888
  // ***********************************************
1869
1889
  // INSTANCE STATE VARIABLES
@@ -1887,8 +1907,8 @@ var Conversation = _webexCore.WebexPlugin.extend({
1887
1907
  /* eslint-disable no-loop-func */
1888
1908
  _loop = /*#__PURE__*/_regenerator.default.mark(function _loop() {
1889
1909
  var _rootActivityManager, getRootActivityHash, addNewRoot, _noMoreActivitiesMana, getNoMoreActs, checkAndSetNoMoreActs, checkAndSetNoOlderActs, checkAndSetNoNewerActs, getActivityHandlerByType, handleNewActivity, handleNewActivities, handleOlderQuery, handleNewerQuery, handleSearch, getQueryResponseHandler, incrementLoopCounter, _loop2, orderedActivities, getRepliesByParentId, orderedRoots, nextOptions, currentOldestPublishedDate, currentNewestPublishedDate;
1890
- return _regenerator.default.wrap(function _loop$(_context11) {
1891
- while (1) switch (_context11.prev = _context11.next) {
1910
+ return _regenerator.default.wrap(function _loop$(_context12) {
1911
+ while (1) switch (_context12.prev = _context12.next) {
1892
1912
  case 0:
1893
1913
  // ***********************************************
1894
1914
  // EXECUTION STATE VARIABLES
@@ -1942,8 +1962,8 @@ var Conversation = _webexCore.WebexPlugin.extend({
1942
1962
  incrementLoopCounter = (0, _activityThreadOrdering.getLoopCounterFailsafe)();
1943
1963
  _loop2 = /*#__PURE__*/_regenerator.default.mark(function _loop2() {
1944
1964
  var allBatchActivitiesConfig, $allBatchActivitiesFetch, $fetchRequests, params, $parentsFetch, _yield$_awaitAsyncGen, _yield$_awaitAsyncGen2, allBatchActivities, _yield$_awaitAsyncGen3, parents, handler, _parents$reply, replyIds, _parents$edit, editIds, _parents$reaction, reactionIds, $reactionFetches, $replyFetches, $editFetches, _iterator4, _step4, activity, actId, childFetchOptions, _yield$_awaitAsyncGen4, _yield$_awaitAsyncGen5, reactions, replies, edits, newReplyReactions, allReactions, rootActivityHash, visibleActivitiesCount, _iterator5, _step5, rootActivity, rootId, repliesByRootId, currentOldestPublishedDate, currentNewestPublishedDate;
1945
- return _regenerator.default.wrap(function _loop2$(_context10) {
1946
- while (1) switch (_context10.prev = _context10.next) {
1965
+ return _regenerator.default.wrap(function _loop2$(_context11) {
1966
+ while (1) switch (_context11.prev = _context11.next) {
1947
1967
  case 0:
1948
1968
  // count loops and throw if we detect infinite loop
1949
1969
  incrementLoopCounter();
@@ -1968,10 +1988,10 @@ var Conversation = _webexCore.WebexPlugin.extend({
1968
1988
  }
1969
1989
 
1970
1990
  // we dont always need to fetch for parents
1971
- _context10.next = 7;
1991
+ _context11.next = 7;
1972
1992
  return (0, _awaitAsyncGenerator2.default)(_promise.default.all($fetchRequests));
1973
1993
  case 7:
1974
- _yield$_awaitAsyncGen = _context10.sent;
1994
+ _yield$_awaitAsyncGen = _context11.sent;
1975
1995
  _yield$_awaitAsyncGen2 = (0, _slicedToArray2.default)(_yield$_awaitAsyncGen, 2);
1976
1996
  allBatchActivities = _yield$_awaitAsyncGen2[0];
1977
1997
  _yield$_awaitAsyncGen3 = _yield$_awaitAsyncGen2[1];
@@ -1987,7 +2007,7 @@ var Conversation = _webexCore.WebexPlugin.extend({
1987
2007
  */
1988
2008
  _parents$reply = parents.reply, replyIds = _parents$reply === void 0 ? [] : _parents$reply, _parents$edit = parents.edit, editIds = _parents$edit === void 0 ? [] : _parents$edit, _parents$reaction = parents.reaction, reactionIds = _parents$reaction === void 0 ? [] : _parents$reaction; // if no parent IDs returned, do nothing
1989
2009
  if (!(replyIds.length || editIds.length || reactionIds.length)) {
1990
- _context10.next = 35;
2010
+ _context11.next = 35;
1991
2011
  break;
1992
2012
  }
1993
2013
  $reactionFetches = [];
@@ -2028,15 +2048,15 @@ var Conversation = _webexCore.WebexPlugin.extend({
2028
2048
  } finally {
2029
2049
  _iterator4.f();
2030
2050
  }
2031
- _context10.next = 23;
2051
+ _context11.next = 23;
2032
2052
  return (0, _awaitAsyncGenerator2.default)(_promise.default.all([_promise.default.all($reactionFetches), _promise.default.all($replyFetches), _promise.default.all($editFetches)]));
2033
2053
  case 23:
2034
- _yield$_awaitAsyncGen4 = _context10.sent;
2054
+ _yield$_awaitAsyncGen4 = _context11.sent;
2035
2055
  _yield$_awaitAsyncGen5 = (0, _slicedToArray2.default)(_yield$_awaitAsyncGen4, 3);
2036
2056
  reactions = _yield$_awaitAsyncGen5[0];
2037
2057
  replies = _yield$_awaitAsyncGen5[1];
2038
2058
  edits = _yield$_awaitAsyncGen5[2];
2039
- _context10.next = 30;
2059
+ _context11.next = 30;
2040
2060
  return (0, _awaitAsyncGenerator2.default)(_promise.default.all(replies.filter(function (reply) {
2041
2061
  return replyIds.includes(reply.id);
2042
2062
  }).map(function (reply) {
@@ -2046,7 +2066,7 @@ var Conversation = _webexCore.WebexPlugin.extend({
2046
2066
  });
2047
2067
  })));
2048
2068
  case 30:
2049
- newReplyReactions = _context10.sent;
2069
+ newReplyReactions = _context11.sent;
2050
2070
  allReactions = [].concat((0, _toConsumableArray2.default)(reactions), (0, _toConsumableArray2.default)(newReplyReactions)); // stick them into activity hashes
2051
2071
  replies.forEach(function (replyArr) {
2052
2072
  return handleNewActivities(replyArr);
@@ -2078,10 +2098,10 @@ var Conversation = _webexCore.WebexPlugin.extend({
2078
2098
  _iterator5.f();
2079
2099
  }
2080
2100
  if (!(visibleActivitiesCount >= minActivities)) {
2081
- _context10.next = 41;
2101
+ _context11.next = 41;
2082
2102
  break;
2083
2103
  }
2084
- return _context10.abrupt("return", 1);
2104
+ return _context11.abrupt("return", 1);
2085
2105
  case 41:
2086
2106
  checkAndSetNoMoreActs(queryType, visibleActivitiesCount, batchSize);
2087
2107
 
@@ -2118,24 +2138,24 @@ var Conversation = _webexCore.WebexPlugin.extend({
2118
2138
  }
2119
2139
  case 48:
2120
2140
  case "end":
2121
- return _context10.stop();
2141
+ return _context11.stop();
2122
2142
  }
2123
2143
  }, _loop2);
2124
2144
  });
2125
2145
  case 11:
2126
2146
  if (getNoMoreActs()) {
2127
- _context11.next = 17;
2147
+ _context12.next = 17;
2128
2148
  break;
2129
2149
  }
2130
- return _context11.delegateYield(_loop2(), "t0", 13);
2150
+ return _context12.delegateYield(_loop2(), "t0", 13);
2131
2151
  case 13:
2132
- if (!_context11.t0) {
2133
- _context11.next = 15;
2152
+ if (!_context12.t0) {
2153
+ _context12.next = 15;
2134
2154
  break;
2135
2155
  }
2136
- return _context11.abrupt("break", 17);
2156
+ return _context12.abrupt("break", 17);
2137
2157
  case 15:
2138
- _context11.next = 11;
2158
+ _context12.next = 11;
2139
2159
  break;
2140
2160
  case 17:
2141
2161
  orderedActivities = [];
@@ -2191,12 +2211,12 @@ var Conversation = _webexCore.WebexPlugin.extend({
2191
2211
  return orderedActivities.push(reply);
2192
2212
  });
2193
2213
  });
2194
- _context11.next = 23;
2214
+ _context12.next = 23;
2195
2215
  return orderedActivities;
2196
2216
  case 23:
2197
- nextOptions = _context11.sent;
2217
+ nextOptions = _context12.sent;
2198
2218
  if (!nextOptions) {
2199
- _context11.next = 32;
2219
+ _context12.next = 32;
2200
2220
  break;
2201
2221
  }
2202
2222
  minActivities = nextOptions.minActivities || minActivities;
@@ -2209,39 +2229,39 @@ var Conversation = _webexCore.WebexPlugin.extend({
2209
2229
  newestPublishedDate: currentNewestPublishedDate,
2210
2230
  batchSize: batchSize
2211
2231
  });
2212
- _context11.next = 33;
2232
+ _context12.next = 33;
2213
2233
  break;
2214
2234
  case 32:
2215
- return _context11.abrupt("return", {
2235
+ return _context12.abrupt("return", {
2216
2236
  v: void 0
2217
2237
  });
2218
2238
  case 33:
2219
2239
  case "end":
2220
- return _context11.stop();
2240
+ return _context12.stop();
2221
2241
  }
2222
2242
  }, _loop);
2223
2243
  });
2224
2244
  case 9:
2225
2245
  if (!true) {
2226
- _context12.next = 16;
2246
+ _context13.next = 16;
2227
2247
  break;
2228
2248
  }
2229
- return _context12.delegateYield(_loop(), "t0", 11);
2249
+ return _context13.delegateYield(_loop(), "t0", 11);
2230
2250
  case 11:
2231
- _ret = _context12.t0;
2251
+ _ret = _context13.t0;
2232
2252
  if (!_ret) {
2233
- _context12.next = 14;
2253
+ _context13.next = 14;
2234
2254
  break;
2235
2255
  }
2236
- return _context12.abrupt("return", _ret.v);
2256
+ return _context13.abrupt("return", _ret.v);
2237
2257
  case 14:
2238
- _context12.next = 9;
2258
+ _context13.next = 9;
2239
2259
  break;
2240
2260
  case 16:
2241
2261
  case "end":
2242
- return _context12.stop();
2262
+ return _context13.stop();
2243
2263
  }
2244
- }, _callee10);
2264
+ }, _callee11);
2245
2265
  }))();
2246
2266
  },
2247
2267
  /**
@@ -2307,10 +2327,10 @@ var Conversation = _webexCore.WebexPlugin.extend({
2307
2327
  */
2308
2328
  _list: function _list(options) {
2309
2329
  var _this31 = this;
2310
- return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee11() {
2330
+ return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee12() {
2311
2331
  var res, list, limit, results, _iterator6, _step6, result, items;
2312
- return _regenerator.default.wrap(function _callee11$(_context13) {
2313
- while (1) switch (_context13.prev = _context13.next) {
2332
+ return _regenerator.default.wrap(function _callee12$(_context14) {
2333
+ while (1) switch (_context14.prev = _context14.next) {
2314
2334
  case 0:
2315
2335
  options.qs = _objectSpread({
2316
2336
  personRefresh: true,
@@ -2318,10 +2338,10 @@ var Conversation = _webexCore.WebexPlugin.extend({
2318
2338
  activitiesLimit: 0,
2319
2339
  participantsLimit: 0
2320
2340
  }, options.qs);
2321
- _context13.next = 3;
2341
+ _context14.next = 3;
2322
2342
  return _this31.request(options);
2323
2343
  case 3:
2324
- res = _context13.sent;
2344
+ res = _context14.sent;
2325
2345
  if (!res.body || !res.body.items || res.body.items.length === 0) {
2326
2346
  list = [];
2327
2347
  } else {
@@ -2334,7 +2354,7 @@ var Conversation = _webexCore.WebexPlugin.extend({
2334
2354
  // The user has more data in another cluster.
2335
2355
  // Follow the 'additionalUrls' for that data.
2336
2356
  if (!res.body.additionalUrls) {
2337
- _context13.next = 14;
2357
+ _context14.next = 14;
2338
2358
  break;
2339
2359
  }
2340
2360
  limit = 0; // If the user asked for a specific amount of data,
@@ -2350,10 +2370,10 @@ var Conversation = _webexCore.WebexPlugin.extend({
2350
2370
  // If the limit is 0 for some reason,
2351
2371
  // don't bother requesting from other clusters
2352
2372
  if (!(!options.limit || limit !== 0)) {
2353
- _context13.next = 14;
2373
+ _context14.next = 14;
2354
2374
  break;
2355
2375
  }
2356
- _context13.next = 11;
2376
+ _context14.next = 11;
2357
2377
  return _promise.default.all(res.body.additionalUrls.map(function (host) {
2358
2378
  var url = "".concat(host, "/").concat(options.resource);
2359
2379
  var newOptions = _objectSpread(_objectSpread({}, options), {}, {
@@ -2366,7 +2386,7 @@ var Conversation = _webexCore.WebexPlugin.extend({
2366
2386
  return _this31.request(newOptions);
2367
2387
  }));
2368
2388
  case 11:
2369
- results = _context13.sent;
2389
+ results = _context14.sent;
2370
2390
  _iterator6 = _createForOfIteratorHelper(results);
2371
2391
  try {
2372
2392
  for (_iterator6.s(); !(_step6 = _iterator6.n()).done;) {
@@ -2385,17 +2405,17 @@ var Conversation = _webexCore.WebexPlugin.extend({
2385
2405
  _iterator6.f();
2386
2406
  }
2387
2407
  case 14:
2388
- _context13.next = 16;
2408
+ _context14.next = 16;
2389
2409
  return _promise.default.all(list.map(function (item) {
2390
2410
  return _this31._recordUUIDs(item);
2391
2411
  }));
2392
2412
  case 16:
2393
- return _context13.abrupt("return", list);
2413
+ return _context14.abrupt("return", list);
2394
2414
  case 17:
2395
2415
  case "end":
2396
- return _context13.stop();
2416
+ return _context14.stop();
2397
2417
  }
2398
- }, _callee11);
2418
+ }, _callee12);
2399
2419
  }))();
2400
2420
  },
2401
2421
  /**
@@ -2504,7 +2524,7 @@ var Conversation = _webexCore.WebexPlugin.extend({
2504
2524
  });
2505
2525
  }));
2506
2526
  },
2507
- version: "3.7.0"
2527
+ version: "3.8.0-next.2"
2508
2528
  });
2509
2529
  ['favorite', 'hide', 'lock', 'mute', 'unfavorite', 'unhide', 'unlock', 'unmute'].forEach(function (verb) {
2510
2530
  Conversation.prototype[verb] = function submitSimpleActivity(conversation, activity) {