MCPcopy Index your code
hub / github.com/Linen-dev/linen.dev / fetchInbox

Function fetchInbox

apps/web/hooks/polling.tsx:18–34  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

16 let mounted = true;
17 setLoading(true);
18 const fetchInbox = () =>
19 fetch()
20 .then((data: any) => {
21 if (mounted) {
22 success(data);
23 }
24 })
25 .catch(() => {
26 if (mounted) {
27 error();
28 }
29 })
30 .finally(() => {
31 if (mounted) {
32 setLoading(false);
33 }
34 });
35 fetchInbox();
36
37 const intervalId = setInterval(() => {

Callers 1

usePollingFunction · 0.85

Calls 2

successFunction · 0.85
errorFunction · 0.50

Tested by

no test coverage detected