@amityco/ts-sdk 7.18.0 → 7.18.1-16ac33a.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (489) hide show
  1. package/dist/__mocks__/marker/api/getMessageMarkers.d.ts +3 -0
  2. package/dist/__mocks__/marker/api/getMessageMarkers.d.ts.map +1 -0
  3. package/dist/__mocks__/marker/api/getSubChannelMarkers.d.ts +3 -0
  4. package/dist/__mocks__/marker/api/getSubChannelMarkers.d.ts.map +1 -0
  5. package/dist/__mocks__/marker/api/index.d.ts +6 -0
  6. package/dist/__mocks__/marker/api/index.d.ts.map +1 -0
  7. package/dist/adRepository/api/tests/integration/getNetworkAds.integration.test.d.ts +2 -0
  8. package/dist/adRepository/api/tests/integration/getNetworkAds.integration.test.d.ts.map +1 -0
  9. package/dist/categoryRepository/api/tests/integration/getCategory.integration.test.d.ts +2 -0
  10. package/dist/categoryRepository/api/tests/integration/getCategory.integration.test.d.ts.map +1 -0
  11. package/dist/categoryRepository/internalApi/tests/integration/getCategory.integration.test.d.ts +2 -0
  12. package/dist/categoryRepository/internalApi/tests/integration/getCategory.integration.test.d.ts.map +1 -0
  13. package/dist/categoryRepository/internalApi/tests/integration/queryCategories.integration.test.d.ts +2 -0
  14. package/dist/categoryRepository/internalApi/tests/integration/queryCategories.integration.test.d.ts.map +1 -0
  15. package/dist/categoryRepository/observers/getCategories.d.ts.map +1 -1
  16. package/dist/categoryRepository/observers/tests/integration/getCategories.integration.test.d.ts +2 -0
  17. package/dist/categoryRepository/observers/tests/integration/getCategories.integration.test.d.ts.map +1 -0
  18. package/dist/categoryRepository/observers/tests/integration/setup.d.ts +10 -0
  19. package/dist/categoryRepository/observers/tests/integration/setup.d.ts.map +1 -0
  20. package/dist/channelRepository/api/createChannel.d.ts.map +1 -1
  21. package/dist/channelRepository/api/tests/integration/createChannel.integration.test.d.ts +2 -0
  22. package/dist/channelRepository/api/tests/integration/createChannel.integration.test.d.ts.map +1 -0
  23. package/dist/channelRepository/api/tests/integration/deleteChannel.integration.test.d.ts +2 -0
  24. package/dist/channelRepository/api/tests/integration/deleteChannel.integration.test.d.ts.map +1 -0
  25. package/dist/channelRepository/api/tests/integration/getChannelByIds.integration.test.d.ts +2 -0
  26. package/dist/channelRepository/api/tests/integration/getChannelByIds.integration.test.d.ts.map +1 -0
  27. package/dist/channelRepository/api/tests/integration/joinChannel.integration.test.d.ts +2 -0
  28. package/dist/channelRepository/api/tests/integration/joinChannel.integration.test.d.ts.map +1 -0
  29. package/dist/channelRepository/api/tests/integration/leaveChannel.integration.test.d.ts +2 -0
  30. package/dist/channelRepository/api/tests/integration/leaveChannel.integration.test.d.ts.map +1 -0
  31. package/dist/channelRepository/api/tests/integration/markChannelsAsReadBySegment.integration.test.d.ts +2 -0
  32. package/dist/channelRepository/api/tests/integration/markChannelsAsReadBySegment.integration.test.d.ts.map +1 -0
  33. package/dist/channelRepository/api/tests/integration/muteChannel.integration.test.d.ts +2 -0
  34. package/dist/channelRepository/api/tests/integration/muteChannel.integration.test.d.ts.map +1 -0
  35. package/dist/channelRepository/api/tests/integration/queryChannels.integration.test.d.ts +2 -0
  36. package/dist/channelRepository/api/tests/integration/queryChannels.integration.test.d.ts.map +1 -0
  37. package/dist/channelRepository/api/tests/integration/unmuteChannel.integration.test.d.ts +2 -0
  38. package/dist/channelRepository/api/tests/integration/unmuteChannel.integration.test.d.ts.map +1 -0
  39. package/dist/channelRepository/api/tests/integration/updateChannel.integration.test.d.ts +2 -0
  40. package/dist/channelRepository/api/tests/integration/updateChannel.integration.test.d.ts.map +1 -0
  41. package/dist/channelRepository/observers/getChannel.d.ts.map +1 -1
  42. package/dist/channelRepository/observers/tests/integrations/getChannel.integration.test.d.ts +2 -0
  43. package/dist/channelRepository/observers/tests/integrations/getChannel.integration.test.d.ts.map +1 -0
  44. package/dist/channelRepository/observers/tests/integrations/getChannels.integration.test.d.ts +2 -0
  45. package/dist/channelRepository/observers/tests/integrations/getChannels.integration.test.d.ts.map +1 -0
  46. package/dist/channelRepository/observers/tests/integrations/getMyMembership.integration.test.d.ts +2 -0
  47. package/dist/channelRepository/observers/tests/integrations/getMyMembership.integration.test.d.ts.map +1 -0
  48. package/dist/channelRepository/observers/tests/integrations/getMyMembership.noUser.integration.test.d.ts +2 -0
  49. package/dist/channelRepository/observers/tests/integrations/getMyMembership.noUser.integration.test.d.ts.map +1 -0
  50. package/dist/channelRepository/observers/tests/integrations/getTotalChannelsUnread.integration.test.d.ts +2 -0
  51. package/dist/channelRepository/observers/tests/integrations/getTotalChannelsUnread.integration.test.d.ts.map +1 -0
  52. package/dist/channelRepository/observers/tests/integrations/getTotalChannelsUnread.noUser.integration.test.d.ts +2 -0
  53. package/dist/channelRepository/observers/tests/integrations/getTotalChannelsUnread.noUser.integration.test.d.ts.map +1 -0
  54. package/dist/channelRepository/utils/prepareChannelPayload.d.ts.map +1 -1
  55. package/dist/client/api/tests/integration/accessTokenExpiryWatcher.integration.test.d.ts +2 -0
  56. package/dist/client/api/tests/integration/accessTokenExpiryWatcher.integration.test.d.ts.map +1 -0
  57. package/dist/client/api/tests/integration/accessTokenFunctions.integration.test.d.ts +2 -0
  58. package/dist/client/api/tests/integration/accessTokenFunctions.integration.test.d.ts.map +1 -0
  59. package/dist/client/api/tests/integration/activeUser.branches.integration.test.d.ts +2 -0
  60. package/dist/client/api/tests/integration/activeUser.branches.integration.test.d.ts.map +1 -0
  61. package/dist/client/api/tests/integration/activeUser.noUser.integration.test.d.ts +2 -0
  62. package/dist/client/api/tests/integration/activeUser.noUser.integration.test.d.ts.map +1 -0
  63. package/dist/client/api/tests/integration/createClient.branches.integration.test.d.ts +2 -0
  64. package/dist/client/api/tests/integration/createClient.branches.integration.test.d.ts.map +1 -0
  65. package/dist/client/api/tests/integration/createClient.integration.test.d.ts +2 -0
  66. package/dist/client/api/tests/integration/createClient.integration.test.d.ts.map +1 -0
  67. package/dist/client/api/tests/integration/getSettings.integration.test.d.ts +2 -0
  68. package/dist/client/api/tests/integration/getSettings.integration.test.d.ts.map +1 -0
  69. package/dist/client/api/tests/integration/login.branches.integration.test.d.ts +2 -0
  70. package/dist/client/api/tests/integration/login.branches.integration.test.d.ts.map +1 -0
  71. package/dist/client/api/tests/integration/login.integration.test.d.ts +2 -0
  72. package/dist/client/api/tests/integration/login.integration.test.d.ts.map +1 -0
  73. package/dist/client/api/tests/integration/loginAlternate.integration.test.d.ts +2 -0
  74. package/dist/client/api/tests/integration/loginAlternate.integration.test.d.ts.map +1 -0
  75. package/dist/client/api/tests/integration/loginAsBot.catch.integration.test.d.ts +2 -0
  76. package/dist/client/api/tests/integration/loginAsBot.catch.integration.test.d.ts.map +1 -0
  77. package/dist/client/api/tests/integration/loginAsBot.integration.test.d.ts +2 -0
  78. package/dist/client/api/tests/integration/loginAsBot.integration.test.d.ts.map +1 -0
  79. package/dist/client/api/tests/integration/loginAsBotTerminated.integration.test.d.ts +2 -0
  80. package/dist/client/api/tests/integration/loginAsBotTerminated.integration.test.d.ts.map +1 -0
  81. package/dist/client/api/tests/integration/loginAsVisitor.integration.test.d.ts +2 -0
  82. package/dist/client/api/tests/integration/loginAsVisitor.integration.test.d.ts.map +1 -0
  83. package/dist/client/api/tests/integration/loginAsVisitorTerminated.integration.test.d.ts +2 -0
  84. package/dist/client/api/tests/integration/loginAsVisitorTerminated.integration.test.d.ts.map +1 -0
  85. package/dist/client/api/tests/integration/logout.branches.integration.test.d.ts +2 -0
  86. package/dist/client/api/tests/integration/logout.branches.integration.test.d.ts.map +1 -0
  87. package/dist/client/api/tests/integration/resumeSession.integration.test.d.ts +2 -0
  88. package/dist/client/api/tests/integration/resumeSession.integration.test.d.ts.map +1 -0
  89. package/dist/client/api/tests/integration/resumeSessionLegacy.integration.test.d.ts +2 -0
  90. package/dist/client/api/tests/integration/resumeSessionLegacy.integration.test.d.ts.map +1 -0
  91. package/dist/client/api/tests/integration/sessionState.integration.test.d.ts +2 -0
  92. package/dist/client/api/tests/integration/sessionState.integration.test.d.ts.map +1 -0
  93. package/dist/client/api/tests/integration/setupLoginSubscriptions.branches.integration.test.d.ts +2 -0
  94. package/dist/client/api/tests/integration/setupLoginSubscriptions.branches.integration.test.d.ts.map +1 -0
  95. package/dist/client/api/tests/integration/setupLoginSubscriptions.legacyUnread.integration.test.d.ts +2 -0
  96. package/dist/client/api/tests/integration/setupLoginSubscriptions.legacyUnread.integration.test.d.ts.map +1 -0
  97. package/dist/client/api/tests/integration/utilities.integration.test.d.ts +2 -0
  98. package/dist/client/api/tests/integration/utilities.integration.test.d.ts.map +1 -0
  99. package/dist/client/api/tests/integration/validateAndTerminate.integration.test.d.ts +2 -0
  100. package/dist/client/api/tests/integration/validateAndTerminate.integration.test.d.ts.map +1 -0
  101. package/dist/client/observers/tests/integrations/getUserUnread.integration.test.d.ts +2 -0
  102. package/dist/client/observers/tests/integrations/getUserUnread.integration.test.d.ts.map +1 -0
  103. package/dist/client/observers/tests/integrations/getUserUnreadEdgeCases.integration.test.d.ts +2 -0
  104. package/dist/client/observers/tests/integrations/getUserUnreadEdgeCases.integration.test.d.ts.map +1 -0
  105. package/dist/commentRepository/api/tests/getComment.test.d.ts +2 -0
  106. package/dist/commentRepository/api/tests/getComment.test.d.ts.map +1 -0
  107. package/dist/commentRepository/events/utils.d.ts.map +1 -1
  108. package/dist/commentRepository/observers/tests/integrations/getComment.integration.test.d.ts +2 -0
  109. package/dist/commentRepository/observers/tests/integrations/getComment.integration.test.d.ts.map +1 -0
  110. package/dist/commentRepository/observers/tests/integrations/getComments.integration.test.d.ts +2 -0
  111. package/dist/commentRepository/observers/tests/integrations/getComments.integration.test.d.ts.map +1 -0
  112. package/dist/communityRepository/api/queryCommunities.d.ts.map +1 -1
  113. package/dist/communityRepository/api/test/integration/createCommunity.integration.test.d.ts +2 -0
  114. package/dist/communityRepository/api/test/integration/createCommunity.integration.test.d.ts.map +1 -0
  115. package/dist/communityRepository/api/test/integration/deleteCommunity.integration.test.d.ts +2 -0
  116. package/dist/communityRepository/api/test/integration/deleteCommunity.integration.test.d.ts.map +1 -0
  117. package/dist/communityRepository/api/test/integration/getCommunities.integration.test.d.ts +2 -0
  118. package/dist/communityRepository/api/test/integration/getCommunities.integration.test.d.ts.map +1 -0
  119. package/dist/communityRepository/api/test/integration/getCommunity.integration.test.d.ts +2 -0
  120. package/dist/communityRepository/api/test/integration/getCommunity.integration.test.d.ts.map +1 -0
  121. package/dist/communityRepository/api/test/integration/getRecommendedCommunities.integration.test.d.ts +2 -0
  122. package/dist/communityRepository/api/test/integration/getRecommendedCommunities.integration.test.d.ts.map +1 -0
  123. package/dist/communityRepository/api/test/integration/getTrendingCommunities.integration.test.d.ts +2 -0
  124. package/dist/communityRepository/api/test/integration/getTrendingCommunities.integration.test.d.ts.map +1 -0
  125. package/dist/communityRepository/api/test/integration/joinCommunity.integration.test.d.ts +2 -0
  126. package/dist/communityRepository/api/test/integration/joinCommunity.integration.test.d.ts.map +1 -0
  127. package/dist/communityRepository/api/test/integration/leaveCommunity.integration.test.d.ts +2 -0
  128. package/dist/communityRepository/api/test/integration/leaveCommunity.integration.test.d.ts.map +1 -0
  129. package/dist/communityRepository/api/test/integration/queryCommunities.integration.test.d.ts +2 -0
  130. package/dist/communityRepository/api/test/integration/queryCommunities.integration.test.d.ts.map +1 -0
  131. package/dist/communityRepository/api/test/integration/setup.d.ts +17 -0
  132. package/dist/communityRepository/api/test/integration/setup.d.ts.map +1 -0
  133. package/dist/communityRepository/api/test/integration/updateCommunity.integration.test.d.ts +2 -0
  134. package/dist/communityRepository/api/test/integration/updateCommunity.integration.test.d.ts.map +1 -0
  135. package/dist/communityRepository/communityMembership/api/tests/integration/addMembers.integration.test.d.ts +2 -0
  136. package/dist/communityRepository/communityMembership/api/tests/integration/addMembers.integration.test.d.ts.map +1 -0
  137. package/dist/communityRepository/communityMembership/api/tests/integration/queryCommunityMembers.integration.test.d.ts +2 -0
  138. package/dist/communityRepository/communityMembership/api/tests/integration/queryCommunityMembers.integration.test.d.ts.map +1 -0
  139. package/dist/communityRepository/communityMembership/api/tests/integration/removeMembers.integration.test.d.ts +2 -0
  140. package/dist/communityRepository/communityMembership/api/tests/integration/removeMembers.integration.test.d.ts.map +1 -0
  141. package/dist/communityRepository/communityMembership/api/tests/integration/setup.d.ts +10 -0
  142. package/dist/communityRepository/communityMembership/api/tests/integration/setup.d.ts.map +1 -0
  143. package/dist/communityRepository/communityMembership/observers/tests/integration/getMembers.integration.test.d.ts +2 -0
  144. package/dist/communityRepository/communityMembership/observers/tests/integration/getMembers.integration.test.d.ts.map +1 -0
  145. package/dist/communityRepository/communityMembership/observers/tests/integration/searchMembers.integration.test.d.ts +2 -0
  146. package/dist/communityRepository/communityMembership/observers/tests/integration/searchMembers.integration.test.d.ts.map +1 -0
  147. package/dist/communityRepository/communityMembership/observers/tests/integration/setup.d.ts +8 -0
  148. package/dist/communityRepository/communityMembership/observers/tests/integration/setup.d.ts.map +1 -0
  149. package/dist/communityRepository/communityModeration/api/test/integration/addRoles.integration.test.d.ts +2 -0
  150. package/dist/communityRepository/communityModeration/api/test/integration/addRoles.integration.test.d.ts.map +1 -0
  151. package/dist/communityRepository/communityModeration/api/test/integration/banMembers.integration.test.d.ts +2 -0
  152. package/dist/communityRepository/communityModeration/api/test/integration/banMembers.integration.test.d.ts.map +1 -0
  153. package/dist/communityRepository/communityModeration/api/test/integration/removeRoles.integration.test.d.ts +2 -0
  154. package/dist/communityRepository/communityModeration/api/test/integration/removeRoles.integration.test.d.ts.map +1 -0
  155. package/dist/communityRepository/communityModeration/api/test/integration/setup.d.ts +14 -0
  156. package/dist/communityRepository/communityModeration/api/test/integration/setup.d.ts.map +1 -0
  157. package/dist/communityRepository/communityModeration/api/test/integration/unbanMembers.integration.test.d.ts +2 -0
  158. package/dist/communityRepository/communityModeration/api/test/integration/unbanMembers.integration.test.d.ts.map +1 -0
  159. package/dist/communityRepository/observers/tests/integration/getCommunities.integration.test.d.ts +2 -0
  160. package/dist/communityRepository/observers/tests/integration/getCommunities.integration.test.d.ts.map +1 -0
  161. package/dist/communityRepository/observers/tests/integration/getCommunity.integration.test.d.ts +2 -0
  162. package/dist/communityRepository/observers/tests/integration/getCommunity.integration.test.d.ts.map +1 -0
  163. package/dist/communityRepository/observers/tests/integration/getJoinRequestList.integration.test.d.ts +2 -0
  164. package/dist/communityRepository/observers/tests/integration/getJoinRequestList.integration.test.d.ts.map +1 -0
  165. package/dist/communityRepository/observers/tests/integration/getJoinRequests.integration.test.d.ts +2 -0
  166. package/dist/communityRepository/observers/tests/integration/getJoinRequests.integration.test.d.ts.map +1 -0
  167. package/dist/communityRepository/observers/tests/integration/getRecommendedCommunities.integration.test.d.ts +2 -0
  168. package/dist/communityRepository/observers/tests/integration/getRecommendedCommunities.integration.test.d.ts.map +1 -0
  169. package/dist/communityRepository/observers/tests/integration/getTrendingCommunities.integration.test.d.ts +2 -0
  170. package/dist/communityRepository/observers/tests/integration/getTrendingCommunities.integration.test.d.ts.map +1 -0
  171. package/dist/communityRepository/observers/tests/integration/searchCommunities.integration.test.d.ts +2 -0
  172. package/dist/communityRepository/observers/tests/integration/searchCommunities.integration.test.d.ts.map +1 -0
  173. package/dist/communityRepository/observers/tests/integration/semanticSearchCommunities.integration.test.d.ts +2 -0
  174. package/dist/communityRepository/observers/tests/integration/semanticSearchCommunities.integration.test.d.ts.map +1 -0
  175. package/dist/communityRepository/observers/tests/integration/setup.d.ts +21 -0
  176. package/dist/communityRepository/observers/tests/integration/setup.d.ts.map +1 -0
  177. package/dist/core/transports/mqtt.d.ts.map +1 -1
  178. package/dist/eventRepository/api/tests/integration/createEvent.integration.test.d.ts +2 -0
  179. package/dist/eventRepository/api/tests/integration/createEvent.integration.test.d.ts.map +1 -0
  180. package/dist/eventRepository/api/tests/integration/deleteEvent.integration.test.d.ts +2 -0
  181. package/dist/eventRepository/api/tests/integration/deleteEvent.integration.test.d.ts.map +1 -0
  182. package/dist/eventRepository/api/tests/integration/updateEvent.integration.test.d.ts +2 -0
  183. package/dist/eventRepository/api/tests/integration/updateEvent.integration.test.d.ts.map +1 -0
  184. package/dist/eventRepository/internalApi/tests/integration/createRSVP.integration.test.d.ts +2 -0
  185. package/dist/eventRepository/internalApi/tests/integration/createRSVP.integration.test.d.ts.map +1 -0
  186. package/dist/eventRepository/internalApi/tests/integration/getEvent.integration.test.d.ts +2 -0
  187. package/dist/eventRepository/internalApi/tests/integration/getEvent.integration.test.d.ts.map +1 -0
  188. package/dist/eventRepository/internalApi/tests/integration/getMyRSVP.integration.test.d.ts +2 -0
  189. package/dist/eventRepository/internalApi/tests/integration/getMyRSVP.integration.test.d.ts.map +1 -0
  190. package/dist/eventRepository/internalApi/tests/integration/updateRSVP.integration.test.d.ts +2 -0
  191. package/dist/eventRepository/internalApi/tests/integration/updateRSVP.integration.test.d.ts.map +1 -0
  192. package/dist/eventRepository/observers/tests/integrations/getEvent.integration.test.d.ts +2 -0
  193. package/dist/eventRepository/observers/tests/integrations/getEvent.integration.test.d.ts.map +1 -0
  194. package/dist/eventRepository/observers/tests/integrations/getEvents.integration.test.d.ts +2 -0
  195. package/dist/eventRepository/observers/tests/integrations/getEvents.integration.test.d.ts.map +1 -0
  196. package/dist/eventRepository/observers/tests/integrations/getMyEvents.integration.test.d.ts +2 -0
  197. package/dist/eventRepository/observers/tests/integrations/getMyEvents.integration.test.d.ts.map +1 -0
  198. package/dist/eventRepository/observers/tests/integrations/getRSVPs.integration.test.d.ts +2 -0
  199. package/dist/eventRepository/observers/tests/integrations/getRSVPs.integration.test.d.ts.map +1 -0
  200. package/dist/eventRepository/utils/createEventResponseSubscriber.d.ts +7 -1
  201. package/dist/eventRepository/utils/createEventResponseSubscriber.d.ts.map +1 -1
  202. package/dist/external/api/tests/integration/createUserToken.integration.test.d.ts +2 -0
  203. package/dist/external/api/tests/integration/createUserToken.integration.test.d.ts.map +1 -0
  204. package/dist/feedRepository/api/tests/integration/queryGlobalFeed.integration.test.d.ts +2 -0
  205. package/dist/feedRepository/api/tests/integration/queryGlobalFeed.integration.test.d.ts.map +1 -0
  206. package/dist/feedRepository/observers/tests/integration/getCommunityFeed.integration.test.d.ts +2 -0
  207. package/dist/feedRepository/observers/tests/integration/getCommunityFeed.integration.test.d.ts.map +1 -0
  208. package/dist/feedRepository/observers/tests/integration/getCustomRankingGlobalFeed.integration.test.d.ts +2 -0
  209. package/dist/feedRepository/observers/tests/integration/getCustomRankingGlobalFeed.integration.test.d.ts.map +1 -0
  210. package/dist/feedRepository/observers/tests/integration/getGlobalFeed.integration.test.d.ts +2 -0
  211. package/dist/feedRepository/observers/tests/integration/getGlobalFeed.integration.test.d.ts.map +1 -0
  212. package/dist/feedRepository/observers/tests/integration/getUserFeed.integration.test.d.ts +2 -0
  213. package/dist/feedRepository/observers/tests/integration/getUserFeed.integration.test.d.ts.map +1 -0
  214. package/dist/feedRepository/observers/utils.d.ts.map +1 -1
  215. package/dist/fileRepository/api/tests/integration/deleteFile.integration.test.d.ts +2 -0
  216. package/dist/fileRepository/api/tests/integration/deleteFile.integration.test.d.ts.map +1 -0
  217. package/dist/fileRepository/api/tests/integration/fileUrlWithSize.integration.test.d.ts +2 -0
  218. package/dist/fileRepository/api/tests/integration/fileUrlWithSize.integration.test.d.ts.map +1 -0
  219. package/dist/fileRepository/api/tests/integration/getFile.integration.test.d.ts +2 -0
  220. package/dist/fileRepository/api/tests/integration/getFile.integration.test.d.ts.map +1 -0
  221. package/dist/fileRepository/api/tests/integration/updateAltText.integration.test.d.ts +2 -0
  222. package/dist/fileRepository/api/tests/integration/updateAltText.integration.test.d.ts.map +1 -0
  223. package/dist/fileRepository/api/tests/integration/uploadAudio.integration.test.d.ts +2 -0
  224. package/dist/fileRepository/api/tests/integration/uploadAudio.integration.test.d.ts.map +1 -0
  225. package/dist/fileRepository/api/tests/integration/uploadClip.integration.test.d.ts +2 -0
  226. package/dist/fileRepository/api/tests/integration/uploadClip.integration.test.d.ts.map +1 -0
  227. package/dist/fileRepository/api/tests/integration/uploadFile.integration.test.d.ts +2 -0
  228. package/dist/fileRepository/api/tests/integration/uploadFile.integration.test.d.ts.map +1 -0
  229. package/dist/fileRepository/api/tests/integration/uploadImage.integration.test.d.ts +2 -0
  230. package/dist/fileRepository/api/tests/integration/uploadImage.integration.test.d.ts.map +1 -0
  231. package/dist/fileRepository/api/tests/integration/uploadVideo.integration.test.d.ts +2 -0
  232. package/dist/fileRepository/api/tests/integration/uploadVideo.integration.test.d.ts.map +1 -0
  233. package/dist/index.cjs.js +286 -244
  234. package/dist/index.esm.js +286 -244
  235. package/dist/index.umd.js +3 -3
  236. package/dist/invitationRepository/api/tests/integration/cancelInvitation.integration.test.d.ts +2 -0
  237. package/dist/invitationRepository/api/tests/integration/cancelInvitation.integration.test.d.ts.map +1 -0
  238. package/dist/invitationRepository/observers/tests/integrations/getInvitations.integration.test.d.ts +2 -0
  239. package/dist/invitationRepository/observers/tests/integrations/getInvitations.integration.test.d.ts.map +1 -0
  240. package/dist/invitationRepository/observers/tests/integrations/getInvitations.noUser.integration.test.d.ts +2 -0
  241. package/dist/invitationRepository/observers/tests/integrations/getInvitations.noUser.integration.test.d.ts.map +1 -0
  242. package/dist/invitationRepository/observers/tests/integrations/getMyCommunityInvitations.integration.test.d.ts +2 -0
  243. package/dist/invitationRepository/observers/tests/integrations/getMyCommunityInvitations.integration.test.d.ts.map +1 -0
  244. package/dist/liveReactionRepository/api/tests/integration/createReaction.integration.test.d.ts +2 -0
  245. package/dist/liveReactionRepository/api/tests/integration/createReaction.integration.test.d.ts.map +1 -0
  246. package/dist/liveReactionRepository/events/tests/integration/onLiveReactionCreated.integration.test.d.ts +2 -0
  247. package/dist/liveReactionRepository/events/tests/integration/onLiveReactionCreated.integration.test.d.ts.map +1 -0
  248. package/dist/liveReactionRepository/observers/tests/integrations/getReactions.integration.test.d.ts +2 -0
  249. package/dist/liveReactionRepository/observers/tests/integrations/getReactions.integration.test.d.ts.map +1 -0
  250. package/dist/liveReactionRepository/observers/tests/integrations/getReactions.noUser.integration.test.d.ts +2 -0
  251. package/dist/liveReactionRepository/observers/tests/integrations/getReactions.noUser.integration.test.d.ts.map +1 -0
  252. package/dist/messageRepository/api/tests/integration/createMessage.integration.test.d.ts +2 -0
  253. package/dist/messageRepository/api/tests/integration/createMessage.integration.test.d.ts.map +1 -0
  254. package/dist/messageRepository/api/tests/integration/deleteMessage.integration.test.d.ts +2 -0
  255. package/dist/messageRepository/api/tests/integration/deleteMessage.integration.test.d.ts.map +1 -0
  256. package/dist/messageRepository/api/tests/integration/editMessage.integration.test.d.ts +2 -0
  257. package/dist/messageRepository/api/tests/integration/editMessage.integration.test.d.ts.map +1 -0
  258. package/dist/messageRepository/api/tests/integration/flagMessage.integration.test.d.ts +2 -0
  259. package/dist/messageRepository/api/tests/integration/flagMessage.integration.test.d.ts.map +1 -0
  260. package/dist/messageRepository/api/tests/integration/getDeliveredUsers.integration.test.d.ts +2 -0
  261. package/dist/messageRepository/api/tests/integration/getDeliveredUsers.integration.test.d.ts.map +1 -0
  262. package/dist/messageRepository/api/tests/integration/getReadUsers.integration.test.d.ts +2 -0
  263. package/dist/messageRepository/api/tests/integration/getReadUsers.integration.test.d.ts.map +1 -0
  264. package/dist/messageRepository/api/tests/integration/isMessageFlaggedByMe.integration.test.d.ts +2 -0
  265. package/dist/messageRepository/api/tests/integration/isMessageFlaggedByMe.integration.test.d.ts.map +1 -0
  266. package/dist/messageRepository/api/tests/integration/markAsDelivered.integration.test.d.ts +2 -0
  267. package/dist/messageRepository/api/tests/integration/markAsDelivered.integration.test.d.ts.map +1 -0
  268. package/dist/messageRepository/api/tests/integration/queryMessages.integration.test.d.ts +2 -0
  269. package/dist/messageRepository/api/tests/integration/queryMessages.integration.test.d.ts.map +1 -0
  270. package/dist/messageRepository/api/tests/integration/softDeleteMessage.integration.test.d.ts +2 -0
  271. package/dist/messageRepository/api/tests/integration/softDeleteMessage.integration.test.d.ts.map +1 -0
  272. package/dist/messageRepository/api/tests/integration/unflagMessage.integration.test.d.ts +2 -0
  273. package/dist/messageRepository/api/tests/integration/unflagMessage.integration.test.d.ts.map +1 -0
  274. package/dist/messageRepository/api/tests/integration/updateMessage.integration.test.d.ts +2 -0
  275. package/dist/messageRepository/api/tests/integration/updateMessage.integration.test.d.ts.map +1 -0
  276. package/dist/messageRepository/observers/tests/integration/getMessage.integration.test.d.ts +2 -0
  277. package/dist/messageRepository/observers/tests/integration/getMessage.integration.test.d.ts.map +1 -0
  278. package/dist/messageRepository/observers/tests/integration/getMessages.integration.test.d.ts +2 -0
  279. package/dist/messageRepository/observers/tests/integration/getMessages.integration.test.d.ts.map +1 -0
  280. package/dist/notificationTray/api/tests/integration/markItemsSeen.integration.test.d.ts +2 -0
  281. package/dist/notificationTray/api/tests/integration/markItemsSeen.integration.test.d.ts.map +1 -0
  282. package/dist/notificationTray/api/tests/integration/markTraySeen.integration.test.d.ts +2 -0
  283. package/dist/notificationTray/api/tests/integration/markTraySeen.integration.test.d.ts.map +1 -0
  284. package/dist/notificationTray/events/tests/integrations/onNotificationTraySeenUpdated.integration.test.d.ts +2 -0
  285. package/dist/notificationTray/events/tests/integrations/onNotificationTraySeenUpdated.integration.test.d.ts.map +1 -0
  286. package/dist/notificationTray/internalApi/tests/integration/getNotificationTraySeen.integration.test.d.ts +2 -0
  287. package/dist/notificationTray/internalApi/tests/integration/getNotificationTraySeen.integration.test.d.ts.map +1 -0
  288. package/dist/notificationTray/observers/tests/integrations/getNotificationTrayItems.integration.test.d.ts +2 -0
  289. package/dist/notificationTray/observers/tests/integrations/getNotificationTrayItems.integration.test.d.ts.map +1 -0
  290. package/dist/notificationTray/observers/tests/integrations/getNotificationTraySeen.integration.test.d.ts +2 -0
  291. package/dist/notificationTray/observers/tests/integrations/getNotificationTraySeen.integration.test.d.ts.map +1 -0
  292. package/dist/pollRepository/api/tests/integration/closePoll.integration.test.d.ts +2 -0
  293. package/dist/pollRepository/api/tests/integration/closePoll.integration.test.d.ts.map +1 -0
  294. package/dist/pollRepository/api/tests/integration/createPoll.integration.test.d.ts +2 -0
  295. package/dist/pollRepository/api/tests/integration/createPoll.integration.test.d.ts.map +1 -0
  296. package/dist/pollRepository/api/tests/integration/deletePoll.integration.test.d.ts +2 -0
  297. package/dist/pollRepository/api/tests/integration/deletePoll.integration.test.d.ts.map +1 -0
  298. package/dist/pollRepository/api/tests/integration/getPoll.integration.test.d.ts +2 -0
  299. package/dist/pollRepository/api/tests/integration/getPoll.integration.test.d.ts.map +1 -0
  300. package/dist/pollRepository/api/tests/integration/unvotePoll.integration.test.d.ts +2 -0
  301. package/dist/pollRepository/api/tests/integration/unvotePoll.integration.test.d.ts.map +1 -0
  302. package/dist/pollRepository/api/tests/integration/votePoll.integration.test.d.ts +2 -0
  303. package/dist/pollRepository/api/tests/integration/votePoll.integration.test.d.ts.map +1 -0
  304. package/dist/pollRepository/observers/tests/integrations/getPoll.integration.test.d.ts +2 -0
  305. package/dist/pollRepository/observers/tests/integrations/getPoll.integration.test.d.ts.map +1 -0
  306. package/dist/postRepository/api/createAudioPost.d.ts.map +1 -1
  307. package/dist/postRepository/api/createClipPost.d.ts.map +1 -1
  308. package/dist/postRepository/api/createMixedMediaPost.d.ts.map +1 -1
  309. package/dist/postRepository/api/createPost.d.ts.map +1 -1
  310. package/dist/postRepository/api/deletePost.d.ts.map +1 -1
  311. package/dist/postRepository/api/editPost.d.ts.map +1 -1
  312. package/dist/postRepository/api/getPost.d.ts.map +1 -1
  313. package/dist/postRepository/api/pinProduct.d.ts.map +1 -1
  314. package/dist/postRepository/api/tests/integration/approvePost.integration.test.d.ts +2 -0
  315. package/dist/postRepository/api/tests/integration/approvePost.integration.test.d.ts.map +1 -0
  316. package/dist/postRepository/api/tests/integration/createOtherPosts.integration.test.d.ts +2 -0
  317. package/dist/postRepository/api/tests/integration/createOtherPosts.integration.test.d.ts.map +1 -0
  318. package/dist/postRepository/api/tests/integration/declinePost.integration.test.d.ts +2 -0
  319. package/dist/postRepository/api/tests/integration/declinePost.integration.test.d.ts.map +1 -0
  320. package/dist/postRepository/api/tests/integration/deletePost.integration.test.d.ts +2 -0
  321. package/dist/postRepository/api/tests/integration/deletePost.integration.test.d.ts.map +1 -0
  322. package/dist/postRepository/api/tests/integration/editPost.integration.test.d.ts +2 -0
  323. package/dist/postRepository/api/tests/integration/editPost.integration.test.d.ts.map +1 -0
  324. package/dist/postRepository/api/tests/integration/flagPost.integration.test.d.ts +2 -0
  325. package/dist/postRepository/api/tests/integration/flagPost.integration.test.d.ts.map +1 -0
  326. package/dist/postRepository/api/tests/integration/getPostByIds.integration.test.d.ts +2 -0
  327. package/dist/postRepository/api/tests/integration/getPostByIds.integration.test.d.ts.map +1 -0
  328. package/dist/postRepository/api/tests/integration/observerCollections.integration.test.d.ts +2 -0
  329. package/dist/postRepository/api/tests/integration/observerCollections.integration.test.d.ts.map +1 -0
  330. package/dist/postRepository/api/unpinProduct.d.ts.map +1 -1
  331. package/dist/postRepository/api/updateProductTags.d.ts.map +1 -1
  332. package/dist/postRepository/observers/utils.d.ts.map +1 -1
  333. package/dist/reactionRepository/api/tests/integration/addReaction.integration.test.d.ts +2 -0
  334. package/dist/reactionRepository/api/tests/integration/addReaction.integration.test.d.ts.map +1 -0
  335. package/dist/reactionRepository/api/tests/integration/queryReactions.integration.test.d.ts +2 -0
  336. package/dist/reactionRepository/api/tests/integration/queryReactions.integration.test.d.ts.map +1 -0
  337. package/dist/reactionRepository/api/tests/integration/queryReactor.integration.test.d.ts +2 -0
  338. package/dist/reactionRepository/api/tests/integration/queryReactor.integration.test.d.ts.map +1 -0
  339. package/dist/reactionRepository/api/tests/integration/removeReaction.integration.test.d.ts +2 -0
  340. package/dist/reactionRepository/api/tests/integration/removeReaction.integration.test.d.ts.map +1 -0
  341. package/dist/reactionRepository/observers/tests/integrations/getReactions.integration.test.d.ts +2 -0
  342. package/dist/reactionRepository/observers/tests/integrations/getReactions.integration.test.d.ts.map +1 -0
  343. package/dist/report/api/tests/integration/createReport.integration.test.d.ts +2 -0
  344. package/dist/report/api/tests/integration/createReport.integration.test.d.ts.map +1 -0
  345. package/dist/report/api/tests/integration/deleteReport.integration.test.d.ts +2 -0
  346. package/dist/report/api/tests/integration/deleteReport.integration.test.d.ts.map +1 -0
  347. package/dist/report/api/tests/integration/isReportedByMe.integration.test.d.ts +2 -0
  348. package/dist/report/api/tests/integration/isReportedByMe.integration.test.d.ts.map +1 -0
  349. package/dist/role/api/tests/integration/getRole.integration.test.d.ts +2 -0
  350. package/dist/role/api/tests/integration/getRole.integration.test.d.ts.map +1 -0
  351. package/dist/role/api/tests/integration/queryRoles.integration.test.d.ts +2 -0
  352. package/dist/role/api/tests/integration/queryRoles.integration.test.d.ts.map +1 -0
  353. package/dist/roomPresenceRepository/api/tests/integration/getRoomOnlineUsers.integration.test.d.ts +2 -0
  354. package/dist/roomPresenceRepository/api/tests/integration/getRoomOnlineUsers.integration.test.d.ts.map +1 -0
  355. package/dist/roomPresenceRepository/api/tests/integration/getRoomUserCount.integration.test.d.ts +2 -0
  356. package/dist/roomPresenceRepository/api/tests/integration/getRoomUserCount.integration.test.d.ts.map +1 -0
  357. package/dist/roomPresenceRepository/api/tests/integration/startHeartbeat.integration.test.d.ts +2 -0
  358. package/dist/roomPresenceRepository/api/tests/integration/startHeartbeat.integration.test.d.ts.map +1 -0
  359. package/dist/roomPresenceRepository/api/tests/integration/stopHeartbeat.integration.test.d.ts +2 -0
  360. package/dist/roomPresenceRepository/api/tests/integration/stopHeartbeat.integration.test.d.ts.map +1 -0
  361. package/dist/roomRepository/api/analytics/WatchSessionStorage.d.ts +1 -1
  362. package/dist/roomRepository/api/analytics/WatchSessionStorage.d.ts.map +1 -1
  363. package/dist/roomRepository/api/tests/integration/createRoom.integration.test.d.ts +2 -0
  364. package/dist/roomRepository/api/tests/integration/createRoom.integration.test.d.ts.map +1 -0
  365. package/dist/roomRepository/api/tests/integration/deleteRoom.integration.test.d.ts +2 -0
  366. package/dist/roomRepository/api/tests/integration/deleteRoom.integration.test.d.ts.map +1 -0
  367. package/dist/roomRepository/api/tests/integration/getBroadcasterData.integration.test.d.ts +2 -0
  368. package/dist/roomRepository/api/tests/integration/getBroadcasterData.integration.test.d.ts.map +1 -0
  369. package/dist/roomRepository/api/tests/integration/getRecordedUrl.integration.test.d.ts +2 -0
  370. package/dist/roomRepository/api/tests/integration/getRecordedUrl.integration.test.d.ts.map +1 -0
  371. package/dist/roomRepository/api/tests/integration/leaveRoom.integration.test.d.ts +2 -0
  372. package/dist/roomRepository/api/tests/integration/leaveRoom.integration.test.d.ts.map +1 -0
  373. package/dist/roomRepository/api/tests/integration/removeParticipant.integration.test.d.ts +2 -0
  374. package/dist/roomRepository/api/tests/integration/removeParticipant.integration.test.d.ts.map +1 -0
  375. package/dist/roomRepository/api/tests/integration/roomAnalytics.integration.test.d.ts +2 -0
  376. package/dist/roomRepository/api/tests/integration/roomAnalytics.integration.test.d.ts.map +1 -0
  377. package/dist/roomRepository/api/tests/integration/setup.d.ts +12 -0
  378. package/dist/roomRepository/api/tests/integration/setup.d.ts.map +1 -1
  379. package/dist/roomRepository/api/tests/integration/stopRoom.integration.test.d.ts +2 -0
  380. package/dist/roomRepository/api/tests/integration/stopRoom.integration.test.d.ts.map +1 -0
  381. package/dist/roomRepository/api/tests/integration/updateRoom.integration.test.d.ts +2 -0
  382. package/dist/roomRepository/api/tests/integration/updateRoom.integration.test.d.ts.map +1 -0
  383. package/dist/roomRepository/observers/tests/integration/getRoom.integration.test.d.ts +2 -0
  384. package/dist/roomRepository/observers/tests/integration/getRoom.integration.test.d.ts.map +1 -0
  385. package/dist/roomRepository/observers/tests/integration/getRooms.integration.test.d.ts +2 -0
  386. package/dist/roomRepository/observers/tests/integration/getRooms.integration.test.d.ts.map +1 -0
  387. package/dist/roomRepository/observers/tests/integration/observerUtils.integration.test.d.ts +2 -0
  388. package/dist/roomRepository/observers/tests/integration/observerUtils.integration.test.d.ts.map +1 -0
  389. package/dist/roomRepository/observers/tests/integration/setup.d.ts +2 -0
  390. package/dist/roomRepository/observers/tests/integration/setup.d.ts.map +1 -0
  391. package/dist/storyRepository/api/tests/integration/createImageStory.integration.test.d.ts +2 -0
  392. package/dist/storyRepository/api/tests/integration/createImageStory.integration.test.d.ts.map +1 -0
  393. package/dist/storyRepository/api/tests/integration/createVideoStory.integration.test.d.ts +2 -0
  394. package/dist/storyRepository/api/tests/integration/createVideoStory.integration.test.d.ts.map +1 -0
  395. package/dist/storyRepository/api/tests/integration/hardDeleteStory.integration.test.d.ts +2 -0
  396. package/dist/storyRepository/api/tests/integration/hardDeleteStory.integration.test.d.ts.map +1 -0
  397. package/dist/storyRepository/api/tests/integration/softDeleteStory.integration.test.d.ts +2 -0
  398. package/dist/storyRepository/api/tests/integration/softDeleteStory.integration.test.d.ts.map +1 -0
  399. package/dist/storyRepository/internalApi/tests/integration/getStoryByStoryId.integration.test.d.ts +2 -0
  400. package/dist/storyRepository/internalApi/tests/integration/getStoryByStoryId.integration.test.d.ts.map +1 -0
  401. package/dist/storyRepository/observers/tests/integration/getActiveStoriesByTarget.integration.test.d.ts +2 -0
  402. package/dist/storyRepository/observers/tests/integration/getActiveStoriesByTarget.integration.test.d.ts.map +1 -0
  403. package/dist/storyRepository/observers/tests/integration/getGlobalStoryTargets.integration.test.d.ts +2 -0
  404. package/dist/storyRepository/observers/tests/integration/getGlobalStoryTargets.integration.test.d.ts.map +1 -0
  405. package/dist/storyRepository/observers/tests/integration/getStoriesByTargetIds.integration.test.d.ts +2 -0
  406. package/dist/storyRepository/observers/tests/integration/getStoriesByTargetIds.integration.test.d.ts.map +1 -0
  407. package/dist/storyRepository/observers/tests/integration/getStoryByStoryId.integration.test.d.ts +2 -0
  408. package/dist/storyRepository/observers/tests/integration/getStoryByStoryId.integration.test.d.ts.map +1 -0
  409. package/dist/storyRepository/observers/tests/integration/getTargetById.integration.test.d.ts +2 -0
  410. package/dist/storyRepository/observers/tests/integration/getTargetById.integration.test.d.ts.map +1 -0
  411. package/dist/storyRepository/observers/tests/integration/getTargetsByTargetIds.integration.test.d.ts +2 -0
  412. package/dist/storyRepository/observers/tests/integration/getTargetsByTargetIds.integration.test.d.ts.map +1 -0
  413. package/dist/streamRepository/api/tests/integration/createStream.integration.test.d.ts +2 -0
  414. package/dist/streamRepository/api/tests/integration/createStream.integration.test.d.ts.map +1 -0
  415. package/dist/streamRepository/api/tests/integration/deleteStream.integration.test.d.ts +2 -0
  416. package/dist/streamRepository/api/tests/integration/deleteStream.integration.test.d.ts.map +1 -0
  417. package/dist/streamRepository/api/tests/integration/disposeStream.integration.test.d.ts +2 -0
  418. package/dist/streamRepository/api/tests/integration/disposeStream.integration.test.d.ts.map +1 -0
  419. package/dist/streamRepository/api/tests/integration/editStream.integration.test.d.ts +2 -0
  420. package/dist/streamRepository/api/tests/integration/editStream.integration.test.d.ts.map +1 -0
  421. package/dist/streamRepository/api/tests/integration/updateStream.integration.test.d.ts +2 -0
  422. package/dist/streamRepository/api/tests/integration/updateStream.integration.test.d.ts.map +1 -0
  423. package/dist/streamRepository/observers/tests/integration/getStreamById.integration.test.d.ts +2 -0
  424. package/dist/streamRepository/observers/tests/integration/getStreamById.integration.test.d.ts.map +1 -0
  425. package/dist/subChannelRepository/api/deleteSubChannel.d.ts.map +1 -1
  426. package/dist/subChannelRepository/api/getSubChannel.d.ts.map +1 -1
  427. package/dist/subChannelRepository/api/tests/integration/createSubChannel.integration.test.d.ts +2 -0
  428. package/dist/subChannelRepository/api/tests/integration/createSubChannel.integration.test.d.ts.map +1 -0
  429. package/dist/subChannelRepository/api/tests/integration/deleteSubChannel.integration.test.d.ts +2 -0
  430. package/dist/subChannelRepository/api/tests/integration/deleteSubChannel.integration.test.d.ts.map +1 -0
  431. package/dist/subChannelRepository/api/tests/integration/getSubChannel.integration.test.d.ts +2 -0
  432. package/dist/subChannelRepository/api/tests/integration/getSubChannel.integration.test.d.ts.map +1 -0
  433. package/dist/subChannelRepository/api/tests/integration/getSubChannels.integration.test.d.ts +2 -0
  434. package/dist/subChannelRepository/api/tests/integration/getSubChannels.integration.test.d.ts.map +1 -0
  435. package/dist/subChannelRepository/api/tests/integration/hardDeleteSubChannel.integration.test.d.ts +2 -0
  436. package/dist/subChannelRepository/api/tests/integration/hardDeleteSubChannel.integration.test.d.ts.map +1 -0
  437. package/dist/subChannelRepository/api/tests/integration/markAsReadBySegment.integration.test.d.ts +2 -0
  438. package/dist/subChannelRepository/api/tests/integration/markAsReadBySegment.integration.test.d.ts.map +1 -0
  439. package/dist/subChannelRepository/api/tests/integration/querySubChannels.integration.test.d.ts +2 -0
  440. package/dist/subChannelRepository/api/tests/integration/querySubChannels.integration.test.d.ts.map +1 -0
  441. package/dist/subChannelRepository/api/tests/integration/readingAPI.integration.test.d.ts +2 -0
  442. package/dist/subChannelRepository/api/tests/integration/readingAPI.integration.test.d.ts.map +1 -0
  443. package/dist/subChannelRepository/api/tests/integration/softDeleteSubChannel.integration.test.d.ts +2 -0
  444. package/dist/subChannelRepository/api/tests/integration/softDeleteSubChannel.integration.test.d.ts.map +1 -0
  445. package/dist/subChannelRepository/api/tests/integration/startReadingAPI.integration.test.d.ts +2 -0
  446. package/dist/subChannelRepository/api/tests/integration/startReadingAPI.integration.test.d.ts.map +1 -0
  447. package/dist/subChannelRepository/api/tests/integration/stopReadingAPI.integration.test.d.ts +2 -0
  448. package/dist/subChannelRepository/api/tests/integration/stopReadingAPI.integration.test.d.ts.map +1 -0
  449. package/dist/subChannelRepository/api/tests/integration/updateSubChannel.integration.test.d.ts +2 -0
  450. package/dist/subChannelRepository/api/tests/integration/updateSubChannel.integration.test.d.ts.map +1 -0
  451. package/dist/subChannelRepository/observers/getSubChannel.d.ts.map +1 -1
  452. package/dist/subChannelRepository/observers/tests/integrations/getSubChannel.integration.test.d.ts +2 -0
  453. package/dist/subChannelRepository/observers/tests/integrations/getSubChannel.integration.test.d.ts.map +1 -0
  454. package/dist/subChannelRepository/observers/tests/integrations/getSubChannels.integration.test.d.ts +2 -0
  455. package/dist/subChannelRepository/observers/tests/integrations/getSubChannels.integration.test.d.ts.map +1 -0
  456. package/dist/userRepository/api/queryBlockedUsers.d.ts.map +1 -1
  457. package/dist/userRepository/api/tests/integration/flagUser.integration.test.d.ts +2 -0
  458. package/dist/userRepository/api/tests/integration/flagUser.integration.test.d.ts.map +1 -0
  459. package/dist/userRepository/api/tests/integration/getAllBlockedUsers.integration.test.d.ts +2 -0
  460. package/dist/userRepository/api/tests/integration/getAllBlockedUsers.integration.test.d.ts.map +1 -0
  461. package/dist/userRepository/api/tests/integration/getUser.integration.test.d.ts +2 -0
  462. package/dist/userRepository/api/tests/integration/getUser.integration.test.d.ts.map +1 -0
  463. package/dist/userRepository/api/tests/integration/getUserByIds.integration.test.d.ts +2 -0
  464. package/dist/userRepository/api/tests/integration/getUserByIds.integration.test.d.ts.map +1 -0
  465. package/dist/userRepository/api/tests/integration/isUserFlaggedByMe.integration.test.d.ts +2 -0
  466. package/dist/userRepository/api/tests/integration/isUserFlaggedByMe.integration.test.d.ts.map +1 -0
  467. package/dist/userRepository/api/tests/integration/queryBlockedUsers.integration.test.d.ts +2 -0
  468. package/dist/userRepository/api/tests/integration/queryBlockedUsers.integration.test.d.ts.map +1 -0
  469. package/dist/userRepository/api/tests/integration/queryUsers.integration.test.d.ts +2 -0
  470. package/dist/userRepository/api/tests/integration/queryUsers.integration.test.d.ts.map +1 -0
  471. package/dist/userRepository/api/tests/integration/unflagUser.integration.test.d.ts +2 -0
  472. package/dist/userRepository/api/tests/integration/unflagUser.integration.test.d.ts.map +1 -0
  473. package/dist/userRepository/api/tests/integration/updateUser.integration.test.d.ts +2 -0
  474. package/dist/userRepository/api/tests/integration/updateUser.integration.test.d.ts.map +1 -0
  475. package/dist/userRepository/observers/tests/integrations/enums.integration.test.d.ts +2 -0
  476. package/dist/userRepository/observers/tests/integrations/enums.integration.test.d.ts.map +1 -0
  477. package/dist/userRepository/observers/tests/integrations/getBlockedUsers.integration.test.d.ts +2 -0
  478. package/dist/userRepository/observers/tests/integrations/getBlockedUsers.integration.test.d.ts.map +1 -0
  479. package/dist/userRepository/observers/tests/integrations/getReachedUsers.integration.test.d.ts +2 -0
  480. package/dist/userRepository/observers/tests/integrations/getReachedUsers.integration.test.d.ts.map +1 -0
  481. package/dist/userRepository/observers/tests/integrations/getUser.integration.test.d.ts +2 -0
  482. package/dist/userRepository/observers/tests/integrations/getUser.integration.test.d.ts.map +1 -0
  483. package/dist/userRepository/observers/tests/integrations/getUsers.integration.test.d.ts +2 -0
  484. package/dist/userRepository/observers/tests/integrations/getUsers.integration.test.d.ts.map +1 -0
  485. package/dist/userRepository/observers/tests/integrations/searchUserByDisplayName.integration.test.d.ts +2 -0
  486. package/dist/userRepository/observers/tests/integrations/searchUserByDisplayName.integration.test.d.ts.map +1 -0
  487. package/dist/utils/tests/dummy/stream.d.ts +4 -11
  488. package/dist/utils/tests/dummy/stream.d.ts.map +1 -1
  489. package/package.json +3 -3
package/dist/index.cjs.js CHANGED
@@ -4734,12 +4734,7 @@ var MqttError;
4734
4734
  MqttError[MqttError["NOT_AUTHORIZED"] = 135] = "NOT_AUTHORIZED";
4735
4735
  })(MqttError || (MqttError = {}));
4736
4736
  function getMqttOptions(params) {
4737
- return Object.assign({ clean: false, clientId: `mqttjs_ + ${Math.random().toString(16).substring(2, 10)}`, protocolId: 'MQTT', protocolVersion: 4, reconnectPeriod: RETRY_BASE_TIMEOUT, will: {
4738
- topic: 'WillMsg',
4739
- payload: 'Connection Closed abnormally..!',
4740
- qos: 0,
4741
- retain: false,
4742
- }, resubscribe: true }, params);
4737
+ return Object.assign({ clean: false, clientId: `mqttjs_ + ${Math.random().toString(16).substring(2, 10)}`, protocolId: 'MQTT', protocolVersion: 4, reconnectPeriod: RETRY_BASE_TIMEOUT, resubscribe: true }, params);
4743
4738
  }
4744
4739
  /**
4745
4740
  * Creates a pre-configured socket.io instance
@@ -5712,6 +5707,7 @@ const getSubChannel$1 = async (subChannelId) => {
5712
5707
  };
5713
5708
  }
5714
5709
  catch (error) {
5710
+ /* c8 ignore next */
5715
5711
  if (checkIfShouldGoesToTombstone(error === null || error === void 0 ? void 0 : error.code)) {
5716
5712
  pushToTombstone('subChannel', subChannelId);
5717
5713
  }
@@ -5958,31 +5954,33 @@ const preUpdateChannelCache = (rawPayload, options = { isMessagePreviewUpdated:
5958
5954
  const updateChannelUnread = ({ currentUserId, channels, channelUsers, }) => {
5959
5955
  const channelsUnread = [];
5960
5956
  for (let i = 0; i < channels.length; i += 1) {
5961
- const cacheKey = ['channelUnread', 'get', channels[i].channelId];
5962
- const channelUser = channelUsers.find(channelUser => channelUser.channelId === channels[i].channelId && channelUser.userId === currentUserId);
5963
- let unreadCount = 0;
5964
- let readToSegment = null;
5965
- let lastMentionedSegment = null;
5966
- let isMentioned = false;
5967
- if (channelUser) {
5968
- readToSegment = channelUser.readToSegment;
5969
- lastMentionedSegment = channelUser.lastMentionedSegment;
5970
- unreadCount = Math.max(channels[i].messageCount - readToSegment, 0);
5971
- isMentioned = lastMentionedSegment > readToSegment;
5972
- }
5973
- const cacheChannelUnread = {
5974
- channelId: channels[i].channelId,
5975
- lastSegment: channels[i].messageCount,
5976
- readToSegment,
5977
- lastMentionedSegment,
5978
- unreadCount,
5979
- isMentioned,
5980
- isDeleted: channels[i].isDeleted || false,
5981
- };
5982
- pushToCache(cacheKey, cacheChannelUnread);
5983
- channelsUnread.push(cacheChannelUnread);
5957
+ if (isUnreadCountSupport(channels[i])) {
5958
+ const cacheKey = ['channelUnread', 'get', channels[i].channelId];
5959
+ const channelUser = channelUsers.find(channelUser => channelUser.channelId === channels[i].channelId && channelUser.userId === currentUserId);
5960
+ let unreadCount = 0;
5961
+ let readToSegment = null;
5962
+ let lastMentionedSegment = null;
5963
+ let isMentioned = false;
5964
+ if (channelUser) {
5965
+ readToSegment = channelUser.readToSegment;
5966
+ lastMentionedSegment = channelUser.lastMentionedSegment;
5967
+ unreadCount = Math.max(channels[i].messageCount - readToSegment, 0);
5968
+ isMentioned = lastMentionedSegment > readToSegment;
5969
+ }
5970
+ const cacheChannelUnread = {
5971
+ channelId: channels[i].channelId,
5972
+ lastSegment: channels[i].messageCount,
5973
+ readToSegment,
5974
+ lastMentionedSegment,
5975
+ unreadCount,
5976
+ isMentioned,
5977
+ isDeleted: channels[i].isDeleted || false,
5978
+ };
5979
+ pushToCache(cacheKey, cacheChannelUnread);
5980
+ channelsUnread.push(cacheChannelUnread);
5981
+ }
5982
+ fireEvent('local.channelUnread.updated', channelsUnread);
5984
5983
  }
5985
- fireEvent('local.channelUnread.updated', channelsUnread);
5986
5984
  };
5987
5985
  const prepareChannelPayload = async (rawPayload, options = { isMessagePreviewUpdated: true }) => {
5988
5986
  const client = getActiveClient();
@@ -6881,12 +6879,17 @@ getChannelByIds$1.locally = (channelIds) => {
6881
6879
  client.log('channel/getChannelByIds.locally', channelIds);
6882
6880
  if (!client.cache)
6883
6881
  return;
6882
+ // queryCache returns undefined only when !cache, but line 92 already guards that case.
6883
+ // The ?. optional chains below are defensive and structurally unreachable after the guard.
6884
+ /* c8 ignore next */
6884
6885
  const cached = (_a = queryCache(['channel', 'get'])) === null || _a === void 0 ? void 0 : _a.filter(({ data }) => {
6885
6886
  return channelIds.includes(data.channelPublicId);
6886
6887
  });
6888
+ /* c8 ignore next */
6887
6889
  if (!cached || (cached === null || cached === void 0 ? void 0 : cached.length) < channelIds.length)
6888
6890
  return;
6889
6891
  const channels = cached.map(({ data }) => data);
6892
+ /* c8 ignore next */
6890
6893
  const oldest = (_b = cached.sort((a, b) => (a.cachedAt < b.cachedAt ? -1 : 1))) === null || _b === void 0 ? void 0 : _b[0];
6891
6894
  return {
6892
6895
  data: channels.map(channel => constructChannelObject(channel)),
@@ -7082,9 +7085,11 @@ getSubChannels$1.locally = (subChannelIds) => {
7082
7085
  const cached = subChannelIds
7083
7086
  .map(channelId => pullFromCache(['subChannel', 'get', channelId]))
7084
7087
  .filter(Boolean);
7088
+ /* c8 ignore next */
7085
7089
  if ((cached === null || cached === void 0 ? void 0 : cached.length) < subChannelIds.length)
7086
7090
  return;
7087
7091
  const subChannels = cached.map(({ data }) => data);
7092
+ /* c8 ignore next */
7088
7093
  const oldest = (_a = cached.sort((a, b) => (a.cachedAt < b.cachedAt ? -1 : 1))) === null || _a === void 0 ? void 0 : _a[0];
7089
7094
  return {
7090
7095
  data: subChannels,
@@ -12612,12 +12617,15 @@ const createChannel = async (bundle) => {
12612
12617
  const client = getActiveClient();
12613
12618
  client.log('user/createChannel', bundle);
12614
12619
  let payload;
12620
+ /* c8 ignore next */
12615
12621
  if ((bundle === null || bundle === void 0 ? void 0 : bundle.type) === 'conversation') {
12616
12622
  payload = await client.http.post('/api/v3/channels/conversation', Object.assign(Object.assign({}, bundle), { isDistinct: true }));
12617
12623
  }
12618
12624
  else {
12619
12625
  const { isPublic } = bundle, restParams = __rest(bundle, ["isPublic"]);
12620
- payload = await client.http.post('/api/v3/channels', Object.assign(Object.assign({}, restParams), { isPublic: (bundle === null || bundle === void 0 ? void 0 : bundle.type) === 'community' ? isPublic : undefined }));
12626
+ payload = await client.http.post('/api/v3/channels', Object.assign(Object.assign({}, restParams), {
12627
+ /* c8 ignore next */
12628
+ isPublic: (bundle === null || bundle === void 0 ? void 0 : bundle.type) === 'community' ? isPublic : undefined }));
12621
12629
  }
12622
12630
  const data = await prepareChannelPayload(payload.data);
12623
12631
  const cachedAt = client.cache && Date.now();
@@ -13195,7 +13203,7 @@ const getWatchSessionStorage = () => {
13195
13203
  return storageInstance;
13196
13204
  };
13197
13205
 
13198
- const privateKey = "-----BEGIN PRIVATE KEY-----\nMIIEvQIBADANBgkqhkiG9w0BAQEFAASCBKcwggSjAgEAAoIBAQDHo80SecH7FuF2\nhFYnb+l26/VN8UMLXAQFLnxciNTEwkGVFMpdezlH8rU2HtUJL4RETogbAOLVY0XM\njs6sPn8G1nALmh9qeDpUtVqFOVtBHxEZ910TLOtQiunjqJKO5nWdqZ71EC3OFluR\niGQkO84BiIFbv37ub7xl3S8XarbtKoLcyVpkDHi+1wx1pgCAn6gtBUgckPL5NR8j\nLseabl3HAXQfhTCKo4tmOFM2Dxwl1IUMmIJrJg/aIU/U0tj/1Eoo7mG0JcNWX19l\nW3EecCbi0ncCJOrkUdwlBrcjaMayaX/ubEwyUeTGiLdyc4L3GRLHjyK8xgVNXRMH\nbZWJ2a5NAgMBAAECggEASxuE+35zTFO/XydKgmvIGcWL9FbgMlXb7Vcf0nBoG945\nbiz0NVc2paraIhJXc608xbYF3qLmtAE1MVBI0ORyRdBHNxY024l/6H6SH60Ed+uI\nM4ysp5ourY6Vj+DLwpdRiI9YDjqYAQDIUmhNxJP7XPhOMoZI6st+xZQBM34ic/bv\nAMSJm9OZphSp3+qXVkFZztr2mxD2EZSJJLYxi8BCdgM2qhazalbcJ6zDKHCZWVWm\n8RRxDGldyMb/237JxETzP40tAlzOZDmBAbUgEnurDJ93RVDIE3rbZUshwgeQd18a\nem096mWgvB1AIKYgsTAR3pw+V19YWAjq/glP6fz8wQKBgQD/oQq+ukKF0PRgBeM5\ngeTjSwsdGppQLmf5ndujvoiz/TpdjDEPu6R8kigQr1rG2t4K/yfdZoI8RdmJD1al\n3Q7N9hofooSy4rj6E3txzWZCHJjHad2cnCp/O26HiReGAl7wTcfTmNdiFHhZQzm5\nJBkvWAiwuvQMNfEbnXxw6/vIDwKBgQDH7fX8gsc77JLvAWgp1MaQN/sbqVb6JeT1\nFQfR8E/WFCSmzQBtNzd5KgYuCeelwr/8DyYytvN2BzCYZXp73gI1jF3YlW5jVn74\nOY6TwQ095digwo6Z0yuxopdIOApKgAkL9PRKgNrqAf3NAyMua6lOGifzjDojC3KU\nfylQmxMn4wKBgHp2B9O/H0dEBw5JQ8W0+JX6yWQz7mEjGiR2/1W+XXb8hQ1zr709\nw1r6Gb+EghRpnZ3fBpYGGbYOMFx8wKHM+N6qW3F0ReX8v2juFGE8aRSa5oYBrWzt\nU16Idjbv8hj84cZ1PJmdyvDtpYn9rpWHOZl4rxEbPvbqkIsOMyNVqdT5AoGAOSge\nmwIIU2le2FVeohbibXiToWTYKMuMmURZ5/r72AgKMmWJKbAPe+Q3wBG01/7FRBpQ\noU8Ma0HC8s6QJbliiEyIx9JwrJWd1vkdecBHONrtA4ibm/5zD2WcOllLF+FitLhi\n3qnX6+6F0IaFGFBPJrTzlv0P4dTz/OAdv52V7GECgYEA2TttOKBAqWllgOaZOkql\nLVMJVmgR7s6tLi1+cEP8ZcapV9aRbRzTAKXm4f8AEhtlG9F9kCOvHYCYGi6JaiWJ\nZkHjeex3T+eE6Di6y5Bm/Ift5jtVhJ4jCVwHOKTMej79NPUFTJfv8hCo29haBDv6\nRXFrv+T21KCcw8k3sJeJWWQ=\n-----END PRIVATE KEY-----";
13206
+ const privateKey = "MIIEpQIBAAKCAQEAwAEc/oZgYIvKSUG/C3mONYLR4ZPgAjMEX4bJ+xqqakUDRtqlNO+eZs2blQ1Ko0DBkqPExyQezvjibH5W2UZBV5RaBTlTcNVKTToMBEGesAfaEcM3qUyQHxdbFYZv6P4sb14dcwxTQ8usmaV8ooiR1Fcaso5ZWYcZ8Hb46FbQ7OoVumsBtPWwfZ4f003o5VCl6AIM6lcLv9UDLlFVYhE+PeXpRHtfWlGqxMvqC9oinlwhL6nWv6VjQXW4nhcib72dPBzfHT7k/PMKto2SxALYdb68ENiAGuJLWi3AUHSyYCJK2w7wIlWfJUAI0v26ub10IpExr6D5QuW2577jjP93iwIDAQABAoIBAFWfqXhwIIatkFY+9Z1+ZcbDQimgsmMIsUiQaX6Lk7e0cxOj6czDlxYtVtaPiNtow2pLkjNkjkCqiP7tEHnwdK9DvylZOTa2R15NJpK3WLcTqVIGhsn/FL5owfvFah6zSsmXZParZm5zY9NZE03ALZhOB9/cz0e3kf/EbpfeL2mW7MApyiUt5i09ycchroOpcWp73ipIxvgigtZyUGFmsQicWhUs28F0D7w4Qfk76yG3nqXeb+BAMhCaIaa/k/aAxhiZG/ygEQWQrcC8gfe+jyicMAQPDEVS9YuUMGsLjIjKuVLZzp2xirQnhc2i2zVNEIvG6soprPOBEMQugzrtX5ECgYEA3b7KAbBIbDl1e4ZSCWhHdHkiWVZHaopsR/LhqDDNhXjWjq3AesgV6k0j9EdziMn/HmmOso0bz99GTV3JZf4A9ztTLumJlkHbdVtlgOqSjrFLj12rH9KXTheyIhWSpUmm8+WB1xasFbqpvJaGo7F3pd2Fqj1XR4mp5BO7c/t7LJ0CgYEA3aouEzXQ9THRKYocdfY69EI1Il1t/d/RSqqd9BxEjxBgxkM13ZiYIn/R4WW/nCUrlmhxG44Aa2Gob4Ahfsui2xKTg/g/3Zk/rAxAEGkfOLGoenaJMD41fH4wUq3FRYwkvnaMb9Hd6f/TlBHslIRa2NN58bSBGJCyBP2b59+2+EcCgYEAixDVRXvV37GlYUOa/XVdosk5Zoe6oDGRuQm0xbNdoUBoZvDHDvme7ONWEiQha/8qtVsD+CyQ7awcPfb8kK9c0bBt+bTS6d4BkTcxkEkMgtrkBVR8Nqfu5jXsLH4VCv4G61zbMhZw8+ut+az5YX2yCN7Frj9sFlxapMRPQmzMEe0CgYEAumsAzM8ZqNv4mAK65Mnr0rhLj1cbxcKRdUYACOgtEFQpzxN/HZnTeFAe5nx3pI3uFlRHq3DFEYnT6dHMWaJQmAULYpVIwMi9L6gtyJ9fzoI6uqMtxRDMUqKdaSsTGOY/kJ6KhQ/unXi1K3XXjR+yd1+C0q+HUm1+CYxvrZYLfskCgYEArsEy+IQOiqniJ0NE2vVUF+UK/IRZaic9YKcpov5Ot7Vvzm/MnnW4N1ljVskocETBWMmPUvNSExVjPebi+rxd8fa5kY8BJScPTzMFbunZn/wjtGdcM10qdlVQ9doG61A/9P3ezFKCfS4AvF/H/59LcSx2Bh28fp3/efiVIOpVd4Y=";
13199
13207
  /*
13200
13208
  * The crypto algorithm used for importing key and signing string
13201
13209
  */
@@ -15059,10 +15067,10 @@ const createEventResponseSubscriber = (event, callback) => {
15059
15067
  const filter = (payload) => {
15060
15068
  const unpackedPayload = prepareEventResponsePayload(payload);
15061
15069
  if (!client.cache) {
15062
- callback(unpackedPayload);
15070
+ callback(unpackedPayload.eventResponses[0]);
15063
15071
  }
15064
15072
  else {
15065
- ingestInCache(unpackedPayload.event[0]);
15073
+ ingestInCache(unpackedPayload);
15066
15074
  const eventResponse = pullFromCache([
15067
15075
  'eventResponse',
15068
15076
  'get',
@@ -17134,6 +17142,195 @@ getMessage$1.locally = (messageId) => {
17134
17142
  };
17135
17143
  };
17136
17144
 
17145
+ class ResetTask {
17146
+ constructor(postId, latestCreatedAt, serverCommentCount) {
17147
+ this.postId = postId;
17148
+ this.latestCreatedAt = latestCreatedAt;
17149
+ this.serverCommentCount = serverCommentCount;
17150
+ }
17151
+ }
17152
+
17153
+ // Task to track comment creation
17154
+ class CreateTask {
17155
+ constructor(postId, commentId, createdAt) {
17156
+ this.postId = postId;
17157
+ this.commentId = commentId;
17158
+ this.createdAt = createdAt;
17159
+ }
17160
+ }
17161
+
17162
+ // Task to track comment deletion
17163
+ class DeleteTask {
17164
+ constructor(postId, commentId) {
17165
+ this.postId = postId;
17166
+ this.commentId = commentId;
17167
+ }
17168
+ }
17169
+
17170
+ class CommentChange {
17171
+ constructor(latestCreatedAt, serverCommentCount) {
17172
+ this.latestCommentCreatedAt = latestCreatedAt;
17173
+ this.serverCommentCount = serverCommentCount;
17174
+ this.createdCommentIds = new Set();
17175
+ this.deletedCommentIds = new Set();
17176
+ }
17177
+ }
17178
+
17179
+ class PostCommentCountEngine {
17180
+ constructor() {
17181
+ this.isProcessing = false;
17182
+ this.tasks = [];
17183
+ this.commentChangeTracker = new Map();
17184
+ }
17185
+ queueCommentChangeTask(task) {
17186
+ this.tasks.push(task);
17187
+ if (!this.isProcessing) {
17188
+ this.processCommentChangeTask();
17189
+ }
17190
+ }
17191
+ processCommentChangeTask() {
17192
+ if (this.isProcessing) {
17193
+ return;
17194
+ }
17195
+ this.isProcessing = true;
17196
+ if (this.tasks.length === 0) {
17197
+ this.isProcessing = false;
17198
+ return;
17199
+ }
17200
+ // Process in capped batches, coalescing updates
17201
+ const batch = this.tasks.splice(0, PostCommentCountEngine.BATCH_SIZE);
17202
+ const modifiedPostIds = new Set();
17203
+ batch.forEach(task => {
17204
+ let modified = false;
17205
+ if (task instanceof ResetTask) {
17206
+ modified = this.processResetTaskInternal(task);
17207
+ }
17208
+ else if (task instanceof CreateTask) {
17209
+ modified = this.processCreateTaskInternal(task);
17210
+ }
17211
+ else if (task instanceof DeleteTask) {
17212
+ modified = this.processDeleteTaskInternal(task);
17213
+ }
17214
+ if (modified) {
17215
+ modifiedPostIds.add(task.postId);
17216
+ }
17217
+ });
17218
+ // Publish one update per modified post
17219
+ modifiedPostIds.forEach(postId => {
17220
+ const count = this.computeCommentCount(postId);
17221
+ PostCommentCountEngine.publishUpdate(postId, count);
17222
+ });
17223
+ this.isProcessing = false;
17224
+ // Recurse if more tasks remain
17225
+ if (this.tasks.length > 0) {
17226
+ this.processCommentChangeTask();
17227
+ }
17228
+ }
17229
+ processResetTaskInternal(task) {
17230
+ // Always creates/overwrites tracker
17231
+ this.commentChangeTracker.set(task.postId, new CommentChange(task.latestCreatedAt, task.serverCommentCount));
17232
+ return true;
17233
+ }
17234
+ processCreateTaskInternal(task) {
17235
+ const tracker = this.commentChangeTracker.get(task.postId);
17236
+ if (!tracker)
17237
+ return false; // No tracker, skip
17238
+ if (tracker.createdCommentIds.has(task.commentId))
17239
+ return false; // Deduplication
17240
+ if (task.createdAt <= tracker.latestCommentCreatedAt)
17241
+ return false; // Timestamp filtering
17242
+ tracker.createdCommentIds.add(task.commentId);
17243
+ return true;
17244
+ }
17245
+ processDeleteTaskInternal(task) {
17246
+ const tracker = this.commentChangeTracker.get(task.postId);
17247
+ if (!tracker)
17248
+ return false; // No tracker, skip
17249
+ if (tracker.deletedCommentIds.has(task.commentId))
17250
+ return false; // Deduplication
17251
+ tracker.deletedCommentIds.add(task.commentId);
17252
+ return true;
17253
+ }
17254
+ computeCommentCount(postId) {
17255
+ const tracker = this.commentChangeTracker.get(postId);
17256
+ if (!tracker)
17257
+ return 0;
17258
+ const count = tracker.serverCommentCount + tracker.createdCommentIds.size - tracker.deletedCommentIds.size;
17259
+ return Math.max(0, count);
17260
+ }
17261
+ static publishUpdate(postId, newCount) {
17262
+ var _a;
17263
+ const queryKey = ['post', 'get', postId];
17264
+ mergeInCache(queryKey, {
17265
+ localCommentCount: newCount,
17266
+ });
17267
+ const postPayload = (_a = pullFromCache(queryKey)) === null || _a === void 0 ? void 0 : _a.data;
17268
+ if (!postPayload)
17269
+ return;
17270
+ fireEvent('local.post.updated', {
17271
+ posts: [postPayload],
17272
+ });
17273
+ }
17274
+ }
17275
+ PostCommentCountEngine.BATCH_SIZE = 50;
17276
+ let instance;
17277
+ var PostCommentCountEngine$1 = {
17278
+ getInstance: () => {
17279
+ if (!instance) {
17280
+ instance = new PostCommentCountEngine();
17281
+ }
17282
+ return instance;
17283
+ },
17284
+ };
17285
+
17286
+ const updateStreamReferences = (streams, streamId, postId) => {
17287
+ if (!streamId)
17288
+ return streams;
17289
+ return streams.map(stream => stream.streamId === streamId
17290
+ ? Object.assign(Object.assign({}, stream), { referenceType: 'post', referenceId: postId, postId }) : stream);
17291
+ };
17292
+ const preparePostPayload = (payload) => {
17293
+ const { posts: postsData, postChildren, videoStreamings } = payload, postPayload = __rest(payload, ["posts", "postChildren", "videoStreamings"]);
17294
+ // Unpack community payload by mapping payload field to postSetting value.
17295
+ const communitiesWithPostSetting = addPostSetting({ communities: postPayload.communities });
17296
+ // map users with community
17297
+ const mappedCommunityUsers = postPayload.communityUsers.map(communityUser => {
17298
+ const user = postPayload.users.find(user => user.userId === communityUser.userId);
17299
+ return Object.assign(Object.assign({}, communityUser), { user });
17300
+ });
17301
+ const communityWithMembershipStatus = updateMembershipStatus(communitiesWithPostSetting, mappedCommunityUsers);
17302
+ let mappedNewStream = [];
17303
+ // feed type
17304
+ const posts = postsData.map(post => {
17305
+ var _a, _b, _c, _d;
17306
+ const feedType = (_a = postPayload.feeds.find(feed => feed.feedId === post.feedId)) === null || _a === void 0 ? void 0 : _a.feedType;
17307
+ const childPosts = payload.postChildren.filter(children => children.parentPostId === post.postId);
17308
+ if (childPosts.length > 0 && isAmityLivestreamPost(childPosts[0])) {
17309
+ mappedNewStream = updateStreamReferences(videoStreamings, (_b = childPosts[0].data) === null || _b === void 0 ? void 0 : _b.streamId, post.postId);
17310
+ }
17311
+ // --- Computed Comment Count: ResetTask integration ---
17312
+ // Find all comments for this post (referenceType === 'post' && referenceId === postId)
17313
+ const allComments = (payload.comments || []).filter((c) => c.referenceType === 'post' && c.referenceId === post.postId);
17314
+ // Compute latestCreatedAt
17315
+ const latestCreatedAt = allComments.length === 0
17316
+ ? new Date().toISOString()
17317
+ : allComments
17318
+ .map(c => c.createdAt)
17319
+ .sort()
17320
+ .at(-1);
17321
+ // Queue ResetTask for this post
17322
+ PostCommentCountEngine$1.getInstance().queueCommentChangeTask(new ResetTask(post.postId, latestCreatedAt, (_c = post.commentsCount) !== null && _c !== void 0 ? _c : 0));
17323
+ return Object.assign(Object.assign({}, post), { childPosts,
17324
+ feedType, localCommentCount: (_d = post.localCommentCount) !== null && _d !== void 0 ? _d : post.commentsCount, pinnedProductId: post === null || post === void 0 ? void 0 : post.pinnedProductId });
17325
+ });
17326
+ return Object.assign(Object.assign({}, postPayload), { postChildren, videoStreamings: mappedNewStream, posts, communities: communityWithMembershipStatus, communityUsers: mappedCommunityUsers });
17327
+ };
17328
+ const prepareSemanticSearchPostPayload = (_a) => {
17329
+ var { searchResult, polls } = _a, postPayload = __rest(_a, ["searchResult", "polls"]);
17330
+ const processedPostPayload = preparePostPayload(postPayload);
17331
+ return Object.assign(Object.assign({}, processedPostPayload), { polls });
17332
+ };
17333
+
17137
17334
  /**
17138
17335
  * ```js
17139
17336
  * import { getPost } from '@amityco/ts-sdk'
@@ -17164,7 +17361,7 @@ const getPost$2 = async (postId) => {
17164
17361
  }
17165
17362
  throw error;
17166
17363
  }
17167
- const data = prepareMembershipPayload(payload, 'communityUsers');
17364
+ const data = preparePostPayload(payload);
17168
17365
  const cachedAt = client.cache && Date.now();
17169
17366
  if (client.cache)
17170
17367
  ingestInCache(data, { cachedAt });
@@ -17582,195 +17779,6 @@ removeReaction.optimistically = (referenceType, referenceId, reactionName) => {
17582
17779
  return !((_d = reaction === null || reaction === void 0 ? void 0 : reaction.myReactions) === null || _d === void 0 ? void 0 : _d.includes(reactionName));
17583
17780
  };
17584
17781
 
17585
- class ResetTask {
17586
- constructor(postId, latestCreatedAt, serverCommentCount) {
17587
- this.postId = postId;
17588
- this.latestCreatedAt = latestCreatedAt;
17589
- this.serverCommentCount = serverCommentCount;
17590
- }
17591
- }
17592
-
17593
- // Task to track comment creation
17594
- class CreateTask {
17595
- constructor(postId, commentId, createdAt) {
17596
- this.postId = postId;
17597
- this.commentId = commentId;
17598
- this.createdAt = createdAt;
17599
- }
17600
- }
17601
-
17602
- // Task to track comment deletion
17603
- class DeleteTask {
17604
- constructor(postId, commentId) {
17605
- this.postId = postId;
17606
- this.commentId = commentId;
17607
- }
17608
- }
17609
-
17610
- class CommentChange {
17611
- constructor(latestCreatedAt, serverCommentCount) {
17612
- this.latestCommentCreatedAt = latestCreatedAt;
17613
- this.serverCommentCount = serverCommentCount;
17614
- this.createdCommentIds = new Set();
17615
- this.deletedCommentIds = new Set();
17616
- }
17617
- }
17618
-
17619
- class PostCommentCountEngine {
17620
- constructor() {
17621
- this.isProcessing = false;
17622
- this.tasks = [];
17623
- this.commentChangeTracker = new Map();
17624
- }
17625
- queueCommentChangeTask(task) {
17626
- this.tasks.push(task);
17627
- if (!this.isProcessing) {
17628
- this.processCommentChangeTask();
17629
- }
17630
- }
17631
- processCommentChangeTask() {
17632
- if (this.isProcessing) {
17633
- return;
17634
- }
17635
- this.isProcessing = true;
17636
- if (this.tasks.length === 0) {
17637
- this.isProcessing = false;
17638
- return;
17639
- }
17640
- // Process in capped batches, coalescing updates
17641
- const batch = this.tasks.splice(0, PostCommentCountEngine.BATCH_SIZE);
17642
- const modifiedPostIds = new Set();
17643
- batch.forEach(task => {
17644
- let modified = false;
17645
- if (task instanceof ResetTask) {
17646
- modified = this.processResetTaskInternal(task);
17647
- }
17648
- else if (task instanceof CreateTask) {
17649
- modified = this.processCreateTaskInternal(task);
17650
- }
17651
- else if (task instanceof DeleteTask) {
17652
- modified = this.processDeleteTaskInternal(task);
17653
- }
17654
- if (modified) {
17655
- modifiedPostIds.add(task.postId);
17656
- }
17657
- });
17658
- // Publish one update per modified post
17659
- modifiedPostIds.forEach(postId => {
17660
- const count = this.computeCommentCount(postId);
17661
- PostCommentCountEngine.publishUpdate(postId, count);
17662
- });
17663
- this.isProcessing = false;
17664
- // Recurse if more tasks remain
17665
- if (this.tasks.length > 0) {
17666
- this.processCommentChangeTask();
17667
- }
17668
- }
17669
- processResetTaskInternal(task) {
17670
- // Always creates/overwrites tracker
17671
- this.commentChangeTracker.set(task.postId, new CommentChange(task.latestCreatedAt, task.serverCommentCount));
17672
- return true;
17673
- }
17674
- processCreateTaskInternal(task) {
17675
- const tracker = this.commentChangeTracker.get(task.postId);
17676
- if (!tracker)
17677
- return false; // No tracker, skip
17678
- if (tracker.createdCommentIds.has(task.commentId))
17679
- return false; // Deduplication
17680
- if (task.createdAt <= tracker.latestCommentCreatedAt)
17681
- return false; // Timestamp filtering
17682
- tracker.createdCommentIds.add(task.commentId);
17683
- return true;
17684
- }
17685
- processDeleteTaskInternal(task) {
17686
- const tracker = this.commentChangeTracker.get(task.postId);
17687
- if (!tracker)
17688
- return false; // No tracker, skip
17689
- if (tracker.deletedCommentIds.has(task.commentId))
17690
- return false; // Deduplication
17691
- tracker.deletedCommentIds.add(task.commentId);
17692
- return true;
17693
- }
17694
- computeCommentCount(postId) {
17695
- const tracker = this.commentChangeTracker.get(postId);
17696
- if (!tracker)
17697
- return 0;
17698
- const count = tracker.serverCommentCount + tracker.createdCommentIds.size - tracker.deletedCommentIds.size;
17699
- return Math.max(0, count);
17700
- }
17701
- static publishUpdate(postId, newCount) {
17702
- var _a;
17703
- const queryKey = ['post', 'get', postId];
17704
- mergeInCache(queryKey, {
17705
- localCommentCount: newCount,
17706
- });
17707
- const postPayload = (_a = pullFromCache(queryKey)) === null || _a === void 0 ? void 0 : _a.data;
17708
- if (!postPayload)
17709
- return;
17710
- fireEvent('local.post.updated', {
17711
- posts: [postPayload],
17712
- });
17713
- }
17714
- }
17715
- PostCommentCountEngine.BATCH_SIZE = 50;
17716
- let instance;
17717
- var PostCommentCountEngine$1 = {
17718
- getInstance: () => {
17719
- if (!instance) {
17720
- instance = new PostCommentCountEngine();
17721
- }
17722
- return instance;
17723
- },
17724
- };
17725
-
17726
- const updateStreamReferences = (streams, streamId, postId) => {
17727
- if (!streamId)
17728
- return streams;
17729
- return streams.map(stream => stream.streamId === streamId
17730
- ? Object.assign(Object.assign({}, stream), { referenceType: 'post', referenceId: postId, postId }) : stream);
17731
- };
17732
- const preparePostPayload = (payload) => {
17733
- const { posts: postsData, postChildren, videoStreamings } = payload, postPayload = __rest(payload, ["posts", "postChildren", "videoStreamings"]);
17734
- // Unpack community payload by mapping payload field to postSetting value.
17735
- const communitiesWithPostSetting = addPostSetting({ communities: postPayload.communities });
17736
- // map users with community
17737
- const mappedCommunityUsers = postPayload.communityUsers.map(communityUser => {
17738
- const user = postPayload.users.find(user => user.userId === communityUser.userId);
17739
- return Object.assign(Object.assign({}, communityUser), { user });
17740
- });
17741
- const communityWithMembershipStatus = updateMembershipStatus(communitiesWithPostSetting, mappedCommunityUsers);
17742
- let mappedNewStream = [];
17743
- // feed type
17744
- const posts = postsData.map(post => {
17745
- var _a, _b, _c, _d;
17746
- const feedType = (_a = postPayload.feeds.find(feed => feed.feedId === post.feedId)) === null || _a === void 0 ? void 0 : _a.feedType;
17747
- const childPosts = payload.postChildren.filter(children => children.parentPostId === post.postId);
17748
- if (childPosts.length > 0 && isAmityLivestreamPost(childPosts[0])) {
17749
- mappedNewStream = updateStreamReferences(videoStreamings, (_b = childPosts[0].data) === null || _b === void 0 ? void 0 : _b.streamId, post.postId);
17750
- }
17751
- // --- Computed Comment Count: ResetTask integration ---
17752
- // Find all comments for this post (referenceType === 'post' && referenceId === postId)
17753
- const allComments = (payload.comments || []).filter((c) => c.referenceType === 'post' && c.referenceId === post.postId);
17754
- // Compute latestCreatedAt
17755
- const latestCreatedAt = allComments.length === 0
17756
- ? new Date().toISOString()
17757
- : allComments
17758
- .map(c => c.createdAt)
17759
- .sort()
17760
- .at(-1);
17761
- // Queue ResetTask for this post
17762
- PostCommentCountEngine$1.getInstance().queueCommentChangeTask(new ResetTask(post.postId, latestCreatedAt, (_c = post.commentsCount) !== null && _c !== void 0 ? _c : 0));
17763
- return Object.assign(Object.assign({}, post), { childPosts,
17764
- feedType, localCommentCount: (_d = post.localCommentCount) !== null && _d !== void 0 ? _d : post.commentsCount, pinnedProductId: post === null || post === void 0 ? void 0 : post.pinnedProductId });
17765
- });
17766
- return Object.assign(Object.assign({}, postPayload), { postChildren, videoStreamings: mappedNewStream, posts, communities: communityWithMembershipStatus, communityUsers: mappedCommunityUsers });
17767
- };
17768
- const prepareSemanticSearchPostPayload = (_a) => {
17769
- var { searchResult, polls } = _a, postPayload = __rest(_a, ["searchResult", "polls"]);
17770
- const processedPostPayload = preparePostPayload(postPayload);
17771
- return Object.assign(Object.assign({}, processedPostPayload), { polls });
17772
- };
17773
-
17774
17782
  const processDeleteChildPost = (payload) => {
17775
17783
  var _a;
17776
17784
  const post = payload.posts[0];
@@ -18088,9 +18096,6 @@ const createCommentEventSubscriber = (event, callback) => {
18088
18096
  comments[0].commentId,
18089
18097
  ]);
18090
18098
  if (['comment.created'].includes(event)) {
18091
- // NOTE: skip adding comment to parent comment children if it's the same user since we use the local event to update instead.
18092
- if (event === 'comment.created' && comment.data.userId === client.userId)
18093
- return;
18094
18099
  if (comments[0].parentId) {
18095
18100
  const parentComment = pullFromCache([
18096
18101
  'comment',
@@ -18106,9 +18111,6 @@ const createCommentEventSubscriber = (event, callback) => {
18106
18111
  }
18107
18112
  }
18108
18113
  if (['comment.deleted'].includes(event)) {
18109
- // NOTE: skip deleting comment to parent comment children if it's the same user since we use the local event to update instead.
18110
- if (event === 'comment.deleted' && comment.data.userId === client.userId)
18111
- return;
18112
18114
  if (comments[0].parentId) {
18113
18115
  const parentComment = pullFromCache([
18114
18116
  'comment',
@@ -19519,7 +19521,9 @@ const deleteSubChannel = async (subChannelId, permanent = false) => {
19519
19521
  await client.http.delete(`/api/v5/message-feeds/${encodeURIComponent(subChannelId)}`, { params: { permanent } });
19520
19522
  const deleted = Object.assign(Object.assign({}, subChannel.data), { isDeleted: true, updatedAt: getFutureDate(subChannel.data.updatedAt) });
19521
19523
  if (permanent) {
19524
+ /* c8 ignore next */
19522
19525
  setTimeout(() => {
19526
+ /* c8 ignore next */
19523
19527
  pushToTombstone('subChannel', subChannelId);
19524
19528
  }, 0);
19525
19529
  }
@@ -20777,9 +20781,11 @@ const getSubChannel = (subChannelId, callback) => {
20777
20781
  callback => {
20778
20782
  const updateMessagePreview = async (subChannel) => {
20779
20783
  const messagePreviewSetting = await client.getMessagePreviewSetting(false);
20784
+ /* c8 ignore next */
20780
20785
  if (messagePreviewSetting === "no-message-preview" /* Amity.MessagePreviewSetting.NO_MESSAGE_PREVIEW */)
20781
20786
  return;
20782
20787
  handleSubChannelUpdated(subChannel);
20788
+ /* c8 ignore next */
20783
20789
  if (subChannel.subChannelId !== subChannelId)
20784
20790
  return;
20785
20791
  callback(subChannel);
@@ -20794,11 +20800,13 @@ const getSubChannel = (subChannelId, callback) => {
20794
20800
  const isTargetSubChannel = subChannelMarkers.find(({ feedId }) => feedId === subChannelId);
20795
20801
  if (!isTargetSubChannel)
20796
20802
  return;
20803
+ /* c8 ignore next 5 */
20797
20804
  const subChannel = (_a = pullFromCache([
20798
20805
  'subChannel',
20799
20806
  'get',
20800
20807
  subChannelId,
20801
20808
  ])) === null || _a === void 0 ? void 0 : _a.data;
20809
+ /* c8 ignore next */
20802
20810
  if (!subChannel)
20803
20811
  return;
20804
20812
  callback(subChannel);
@@ -20814,6 +20822,7 @@ const getSubChannel = (subChannelId, callback) => {
20814
20822
  }, 'subChannelId', 'subChannel'),
20815
20823
  convertEventPayload((callback) => {
20816
20824
  return onMessageCreatedLocal(async (message) => {
20825
+ /* c8 ignore next */
20817
20826
  if (message.subChannelId !== subChannelId)
20818
20827
  return;
20819
20828
  await handleMessageCreatedOnSubChannel(message);
@@ -20823,8 +20832,10 @@ const getSubChannel = (subChannelId, callback) => {
20823
20832
  convertEventPayload((callback) => {
20824
20833
  const updateMessagePreview = async (message) => {
20825
20834
  const messagePreviewSetting = await client.getMessagePreviewSetting(false);
20835
+ /* c8 ignore next */
20826
20836
  if (messagePreviewSetting === "no-message-preview" /* Amity.MessagePreviewSetting.NO_MESSAGE_PREVIEW */)
20827
20837
  return;
20838
+ /* c8 ignore next */
20828
20839
  if (message.subChannelId !== subChannelId)
20829
20840
  return;
20830
20841
  handleMessageUpdatedOnSubChannel(message);
@@ -20836,8 +20847,10 @@ const getSubChannel = (subChannelId, callback) => {
20836
20847
  convertEventPayload((callback) => {
20837
20848
  const updateMessagePreview = async (message) => {
20838
20849
  const messagePreviewSetting = await client.getMessagePreviewSetting(false);
20850
+ /* c8 ignore next */
20839
20851
  if (messagePreviewSetting === "no-message-preview" /* Amity.MessagePreviewSetting.NO_MESSAGE_PREVIEW */)
20840
20852
  return;
20853
+ /* c8 ignore next */
20841
20854
  if (message.subChannelId !== subChannelId)
20842
20855
  return;
20843
20856
  if (messagePreviewSetting === "message-preview-include-deleted" /* Amity.MessagePreviewSetting.MESSAGE_PREVIEW_INCLUDE_DELETED */)
@@ -21297,7 +21310,11 @@ const getChannel = (channelId, callback) => {
21297
21310
  * check equality of previous data and current data to avoid redundancy
21298
21311
  * if equal, do not call the callback function
21299
21312
  * If not equal, assign new snapshot and return callback function
21313
+ *
21314
+ * Note: constructChannelObject always creates new function references (markAsRead, myMembership),
21315
+ * so isEqual will always return false in practice. The early-return branch is structurally unreachable.
21300
21316
  */
21317
+ /* c8 ignore next */
21301
21318
  if (isEqual(snapshot, newSnapshot))
21302
21319
  return;
21303
21320
  snapshot = newSnapshot;
@@ -22842,7 +22859,6 @@ const getCommunities$1 = async (communityIds, includeDiscoverablePrivateCommunit
22842
22859
  * @category Community API
22843
22860
  */
22844
22861
  getCommunities$1.locally = (communityIds) => {
22845
- var _a;
22846
22862
  const client = getActiveClient();
22847
22863
  client.log('community/getCommunities.locally', communityIds);
22848
22864
  if (!client.cache)
@@ -22851,8 +22867,8 @@ getCommunities$1.locally = (communityIds) => {
22851
22867
  .map(communityId => pullFromCache(['community', 'get', communityId]))
22852
22868
  .filter(Boolean);
22853
22869
  const communities = cached.map(({ data }) => data);
22854
- const oldest = (_a = cached.sort((a, b) => (a.cachedAt < b.cachedAt ? -1 : 1))) === null || _a === void 0 ? void 0 : _a[0];
22855
- if ((cached === null || cached === void 0 ? void 0 : cached.length) < communityIds.length)
22870
+ const oldest = cached.sort((a, b) => (a.cachedAt < b.cachedAt ? -1 : 1))[0];
22871
+ if (cached.length < communityIds.length)
22856
22872
  return;
22857
22873
  return {
22858
22874
  data: communities,
@@ -25611,7 +25627,7 @@ const getCategories = (params, callback, config) => {
25611
25627
  let categories = (_a = data.data
25612
25628
  .map(categoryId => pullFromCache(['category', 'get', categoryId]))
25613
25629
  .filter(Boolean)
25614
- .map(({ data }) => LinkedObject.category(data))) !== null && _a !== void 0 ? _a : [];
25630
+ .map(({ data }) => LinkedObject.category(data)) /* c8 ignore next */) !== null && _a !== void 0 ? _a : [];
25615
25631
  if (!params.includeDeleted) {
25616
25632
  categories = filterByPropEquality(categories, 'isDeleted', false);
25617
25633
  }
@@ -25628,6 +25644,7 @@ const getCategories = (params, callback, config) => {
25628
25644
  callback({
25629
25645
  onNextPage: onFetch,
25630
25646
  data: categories,
25647
+ /* c8 ignore next */
25631
25648
  hasNextPage: !!((_b = data.params) === null || _b === void 0 ? void 0 : _b.page),
25632
25649
  loading: data.loading,
25633
25650
  error: data.error,
@@ -25643,6 +25660,7 @@ const getCategories = (params, callback, config) => {
25643
25660
  var _a, _b;
25644
25661
  const collection = (_a = pullFromCache(cacheKey)) === null || _a === void 0 ? void 0 : _a.data;
25645
25662
  const categories = (_b = collection === null || collection === void 0 ? void 0 : collection.data) !== null && _b !== void 0 ? _b : [];
25663
+ /* c8 ignore next */
25646
25664
  if (!initial && categories.length > 0 && !(collection === null || collection === void 0 ? void 0 : collection.params.page))
25647
25665
  return;
25648
25666
  const query = createQuery(queryCategories, Object.assign(Object.assign({}, queryParams), { limit: initial ? limit : undefined, page: !initial ? collection === null || collection === void 0 ? void 0 : collection.params.page : undefined }));
@@ -25743,7 +25761,7 @@ const queryGlobalFeed = async (query) => {
25743
25761
  * @async
25744
25762
  * */
25745
25763
  queryGlobalFeed.locally = (query) => {
25746
- var _a, _b;
25764
+ var _a;
25747
25765
  const client = getActiveClient();
25748
25766
  client.log('post/queryGlobalFeed.locally', query);
25749
25767
  if (!client.cache)
@@ -25759,7 +25777,7 @@ queryGlobalFeed.locally = (query) => {
25759
25777
  .map(({ data }) => data)
25760
25778
  .map(LinkedObject.post);
25761
25779
  const { paging } = data;
25762
- return posts.length === ((_b = data === null || data === void 0 ? void 0 : data.posts) === null || _b === void 0 ? void 0 : _b.length)
25780
+ return posts.length === data.posts.length
25763
25781
  ? {
25764
25782
  data: posts,
25765
25783
  cachedAt,
@@ -25924,8 +25942,8 @@ getCommentByIds.locally = (commentIds) => {
25924
25942
  .map(commentId => pullFromCache(['comment', 'get', commentId]))
25925
25943
  .filter(Boolean);
25926
25944
  const comments = cached.map(({ data }) => data);
25927
- const oldest = (_a = cached.sort((a, b) => (a.cachedAt < b.cachedAt ? -1 : 1))) === null || _a === void 0 ? void 0 : _a[0];
25928
- if ((cached === null || cached === void 0 ? void 0 : cached.length) < commentIds.length)
25945
+ const oldest = (_a = cached.sort((a, b) => a.cachedAt < b.cachedAt ? -1 : 1) /* c8 ignore next */) === null || _a === void 0 ? void 0 : _a[0];
25946
+ if ((cached /* c8 ignore next */ === null || cached /* c8 ignore next */ === void 0 ? void 0 : cached /* c8 ignore next */.length) < commentIds.length)
25929
25947
  return;
25930
25948
  return {
25931
25949
  data: comments.map(comment => LinkedObject.comment(comment)),
@@ -26156,7 +26174,7 @@ const deleteComment = async (commentId, permanent = false) => {
26156
26174
  if (post) {
26157
26175
  const engine = PostCommentCountEngine$1.getInstance();
26158
26176
  engine.queueCommentChangeTask(new DeleteTask(post.postId, commentId));
26159
- if (!deleted.parentId && ((_b = deleted.children) === null || _b === void 0 ? void 0 : _b.length) > 0) {
26177
+ if (!deleted.parentId && ((_b = deleted.children /* c8 ignore next */) === null || _b === void 0 ? void 0 : _b.length) > 0) {
26160
26178
  // NOTE: delete the parent comment will also remove all children comments
26161
26179
  deleted.children.forEach((childCommentId) => {
26162
26180
  engine.queueCommentChangeTask(new DeleteTask(post.postId, childCommentId));
@@ -26825,7 +26843,7 @@ const onPostUpdatedLocal = (callback) => createLocalPostEventSubscriber('local.p
26825
26843
  const commentEventHandler$1 = (callback, eventHandler, cacheKey) => {
26826
26844
  return eventHandler(async (comment) => {
26827
26845
  var _a;
26828
- const currentCollection = (_a = pullFromCache(cacheKey)) === null || _a === void 0 ? void 0 : _a.data;
26846
+ const currentCollection = (_a = pullFromCache(cacheKey) /* c8 ignore next */) === null || _a === void 0 ? void 0 : _a.data;
26829
26847
  if (!currentCollection || !currentCollection.data.includes(comment.referenceId))
26830
26848
  return;
26831
26849
  callback(comment);
@@ -27550,7 +27568,7 @@ class CommunityFeedQueryStreamController extends QueryStreamController {
27550
27568
  const commentEventHandler = (callback, eventHandler, cacheKey, resolveId) => {
27551
27569
  return eventHandler(async (comment) => {
27552
27570
  var _a;
27553
- const currentCollection = (_a = pullFromCache(cacheKey)) === null || _a === void 0 ? void 0 : _a.data;
27571
+ const currentCollection = (_a = pullFromCache(cacheKey) /* c8 ignore next */) === null || _a === void 0 ? void 0 : _a.data;
27554
27572
  if (!currentCollection ||
27555
27573
  !currentCollection.data.includes(resolveId ? resolveId(comment.referenceId) : comment.referenceId))
27556
27574
  return;
@@ -27592,9 +27610,10 @@ const resolvePostIdsFromRooms = (rooms, posts) => {
27592
27610
  return ((_a = rooms
27593
27611
  .map(room => {
27594
27612
  const post = posts.find(post => post.postId === room.referenceId);
27613
+ /* c8 ignore next */
27595
27614
  return post ? getResolver('post')({ postId: post === null || post === void 0 ? void 0 : post.postId }) : undefined;
27596
27615
  })
27597
- .filter(isNonNullable)) !== null && _a !== void 0 ? _a : []);
27616
+ .filter(isNonNullable) /* c8 ignore next */) !== null && _a !== void 0 ? _a : []);
27598
27617
  };
27599
27618
 
27600
27619
  class CommunityFeedLiveCollectionController extends LiveCollectionController {
@@ -27817,7 +27836,9 @@ getPostByIds.locally = (postIds) => {
27817
27836
  .map(postId => pullFromCache(['post', 'get', postId]))
27818
27837
  .filter(Boolean);
27819
27838
  const posts = cached.map(({ data }) => data);
27839
+ /* c8 ignore next */
27820
27840
  const oldest = (_a = cached.sort((a, b) => (a.cachedAt < b.cachedAt ? -1 : 1))) === null || _a === void 0 ? void 0 : _a[0];
27841
+ /* c8 ignore next */
27821
27842
  if ((cached === null || cached === void 0 ? void 0 : cached.length) < postIds.length)
27822
27843
  return;
27823
27844
  return {
@@ -27858,9 +27879,11 @@ const createPost = async (bundle) => {
27858
27879
  const processedAttachments = attachments && attachments.length > 0 && bundle.attachmentProductTags
27859
27880
  ? attachments.map(attachment => {
27860
27881
  var _a;
27882
+ /* c8 ignore next */
27861
27883
  const productTags = (_a = bundle.attachmentProductTags) === null || _a === void 0 ? void 0 : _a.get(attachment.fileId);
27862
27884
  if (productTags)
27863
27885
  return Object.assign(Object.assign({}, attachment), { productTags });
27886
+ /* c8 ignore next */
27864
27887
  return attachment;
27865
27888
  })
27866
27889
  : attachments;
@@ -27905,9 +27928,11 @@ const editPost = async (postId, patch) => {
27905
27928
  const processedAttachments = attachments && attachments.length > 0 && patch.attachmentProductTags
27906
27929
  ? attachments.map(attachment => {
27907
27930
  var _a;
27931
+ /* c8 ignore next */
27908
27932
  const productTags = (_a = patch.attachmentProductTags) === null || _a === void 0 ? void 0 : _a.get(attachment.fileId);
27909
27933
  if (productTags)
27910
27934
  return Object.assign(Object.assign({}, attachment), { productTags });
27935
+ /* c8 ignore next */
27911
27936
  return attachment;
27912
27937
  })
27913
27938
  : attachments;
@@ -27955,9 +27980,12 @@ const deletePost = async (postId, permanent = false) => {
27955
27980
  // later when realtime events covers that for us.
27956
27981
  if (post.data.targetType === 'community') {
27957
27982
  const community = await getCommunity$1(post.data.targetId);
27958
- const communityUsersCache = (_a = queryCache(['communityUsers', 'get'])) !== null && _a !== void 0 ? _a : [];
27983
+ const communityUsersCache =
27984
+ /* c8 ignore next */
27985
+ (_a = queryCache(['communityUsers', 'get'])) !== null && _a !== void 0 ? _a : [];
27959
27986
  const communityUsers = communityUsersCache
27960
27987
  .filter(({ key }) => {
27988
+ /* c8 ignore start */
27961
27989
  // cache key is ['communityUsers', 'get', `${communityId}#`${userId}`}]
27962
27990
  if (key[0] !== 'communityUsers')
27963
27991
  return false;
@@ -27966,6 +27994,7 @@ const deletePost = async (postId, permanent = false) => {
27966
27994
  if (typeof key[2] === 'string')
27967
27995
  return key[2].includes(community.data.communityId);
27968
27996
  return false;
27997
+ /* c8 ignore end */
27969
27998
  })
27970
27999
  .map(({ data }) => data);
27971
28000
  fireEvent('community.updated', {
@@ -27980,7 +28009,9 @@ const deletePost = async (postId, permanent = false) => {
27980
28009
  // to support hard deletion
27981
28010
  const deleted = Object.assign(Object.assign({}, post.data), { isDeleted: true });
27982
28011
  if (permanent) {
28012
+ /* c8 ignore next */
27983
28013
  setTimeout(() => {
28014
+ /* c8 ignore next */
27984
28015
  pushToTombstone('post', postId);
27985
28016
  }, 0);
27986
28017
  }
@@ -28242,9 +28273,11 @@ const createClipPost = async (bundle) => {
28242
28273
  const processedAttachments = attachments && attachments.length > 0 && bundle.attachmentProductTags
28243
28274
  ? attachments.map(attachment => {
28244
28275
  var _a;
28276
+ /* c8 ignore next */
28245
28277
  const productTags = (_a = bundle.attachmentProductTags) === null || _a === void 0 ? void 0 : _a.get(attachment.fileId);
28246
28278
  if (productTags)
28247
28279
  return Object.assign(Object.assign({}, attachment), { productTags });
28280
+ /* c8 ignore next */
28248
28281
  return attachment;
28249
28282
  })
28250
28283
  : attachments;
@@ -28290,9 +28323,11 @@ const createAudioPost = async (bundle) => {
28290
28323
  const { attachments, attachmentProductTags } = bundle, rest = __rest(bundle, ["attachments", "attachmentProductTags"]);
28291
28324
  const processedAttachments = attachments && attachments.length > 0 && attachmentProductTags
28292
28325
  ? attachments.map(attachment => {
28326
+ /* c8 ignore next */
28293
28327
  const productTags = attachmentProductTags === null || attachmentProductTags === void 0 ? void 0 : attachmentProductTags.get(attachment.fileId);
28294
28328
  if (productTags)
28295
28329
  return Object.assign(Object.assign({}, attachment), { productTags });
28330
+ /* c8 ignore next */
28296
28331
  return attachment;
28297
28332
  })
28298
28333
  : attachments;
@@ -28303,6 +28338,7 @@ const createAudioPost = async (bundle) => {
28303
28338
  if (client.cache)
28304
28339
  ingestInCache(data, { cachedAt });
28305
28340
  return {
28341
+ /* c8 ignore next */
28306
28342
  data: postLinkedObject(data === null || data === void 0 ? void 0 : data.posts[0]),
28307
28343
  cachedAt,
28308
28344
  };
@@ -28344,12 +28380,14 @@ const createMixedMediaPost = async (bundle) => {
28344
28380
  const processedAttachments = attachments && attachments.length > 0 && bundle.attachmentProductTags
28345
28381
  ? attachments.map(attachment => {
28346
28382
  var _a;
28383
+ /* c8 ignore next */
28347
28384
  const productTags = (_a = bundle.attachmentProductTags) === null || _a === void 0 ? void 0 : _a.get(attachment.fileId);
28348
28385
  if (productTags)
28349
28386
  return Object.assign(Object.assign({}, attachment), { productTags });
28387
+ /* c8 ignore next */
28350
28388
  return attachment;
28351
28389
  })
28352
- : attachments;
28390
+ : /* c8 ignore next */ attachments;
28353
28391
  const { data: payload } = await client.http.post('/api/v4/posts', Object.assign(Object.assign({}, rest), { attachments: processedAttachments }));
28354
28392
  fireEvent('post.created', payload);
28355
28393
  const data = preparePostPayload(payload);
@@ -28357,6 +28395,7 @@ const createMixedMediaPost = async (bundle) => {
28357
28395
  if (client.cache)
28358
28396
  ingestInCache(data, { cachedAt });
28359
28397
  return {
28398
+ /* c8 ignore next */
28360
28399
  data: postLinkedObject((_a = data === null || data === void 0 ? void 0 : data.posts) === null || _a === void 0 ? void 0 : _a[0]),
28361
28400
  cachedAt,
28362
28401
  };
@@ -28429,6 +28468,7 @@ const pinProduct = async (postId, pinnedProductId) => {
28429
28468
  ingestInCache(payload, { cachedAt });
28430
28469
  fireEvent('local.post.updated', payload);
28431
28470
  return {
28471
+ /* c8 ignore next */
28432
28472
  data: postLinkedObject(data === null || data === void 0 ? void 0 : data.posts[0]),
28433
28473
  cachedAt,
28434
28474
  };
@@ -28460,6 +28500,7 @@ const unpinProduct = async (postId) => {
28460
28500
  ingestInCache(payload, { cachedAt });
28461
28501
  fireEvent('local.post.updated', payload);
28462
28502
  return {
28503
+ /* c8 ignore next */
28463
28504
  data: postLinkedObject(data === null || data === void 0 ? void 0 : data.posts[0]),
28464
28505
  cachedAt,
28465
28506
  };
@@ -28494,6 +28535,7 @@ const updateProductTags = async (postId, productTags) => {
28494
28535
  ingestInCache(payload, { cachedAt });
28495
28536
  fireEvent('local.post.updated', payload);
28496
28537
  return {
28538
+ /* c8 ignore next */
28497
28539
  data: postLinkedObject(data === null || data === void 0 ? void 0 : data.posts[0]),
28498
28540
  cachedAt,
28499
28541
  };