@seamly/web-ui 22.3.5 → 22.3.6

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.
@@ -7610,12 +7610,14 @@ function use_session_expired_command_useSessionExpiredCommand() {
7610
7610
  }
7611
7611
  } = useInterrupt();
7612
7612
  const dispatch = useAppDispatch();
7613
- const seamlyCommands = useSeamlyCommands();
7613
+ const {
7614
+ reset
7615
+ } = useSeamlyCommands();
7614
7616
  const isExpiredError = (originalError === null || originalError === void 0 ? void 0 : originalError.name) === 'SeamlySessionExpiredError';
7615
7617
  const limit = useRef(0);
7616
7618
  const limitTimer = useRef(null);
7617
7619
  useEffect(() => {
7618
- if (isExpiredError && seamlyCommands[action]) {
7620
+ if (isExpiredError && action === 'reset') {
7619
7621
  if (limit.current >= 10) {
7620
7622
  limitTimer.current = setTimeout(() => {
7621
7623
  limit.current = 0;
@@ -7632,12 +7634,12 @@ function use_session_expired_command_useSessionExpiredCommand() {
7632
7634
  return () => {};
7633
7635
  }
7634
7636
  limit.current += 1;
7635
- seamlyCommands[action]();
7637
+ reset();
7636
7638
  }
7637
7639
  return () => {
7638
7640
  if (limitTimer.current) clearTimeout(limitTimer.current);
7639
7641
  };
7640
- }, [action, seamlyCommands, isExpiredError, dispatch]);
7642
+ }, [action, reset, isExpiredError, dispatch]);
7641
7643
  }
7642
7644
  ;// CONCATENATED MODULE: ./src/javascripts/ui/hooks/use-seamly-chat.ts
7643
7645
  var __awaiter = undefined && undefined.__awaiter || function (thisArg, _arguments, P, generator) {