MCPcopy Create free account
hub / github.com/AnukarOP/claude-code-leaked / fetchInfo

Function fetchInfo

source code/components/RemoteEnvironmentDialog.tsx:50–71  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

48 t2 = () => {
49 let cancelled = false;
50 const fetchInfo = async function fetchInfo() {
51 ;
52 try {
53 const result = await getEnvironmentSelectionInfo();
54 if (cancelled) {
55 return;
56 }
57 setEnvironments(result.availableEnvironments);
58 setSelectedEnvironment(result.selectedEnvironment);
59 setSelectedEnvironmentSource(result.selectedEnvironmentSource);
60 setLoadingState(null);
61 } catch (t4) {
62 const err = t4;
63 if (cancelled) {
64 return;
65 }
66 const fetchError = toError(err);
67 logError(fetchError);
68 setError(fetchError.message);
69 setLoadingState(null);
70 }
71 };
72 fetchInfo();
73 return () => {
74 cancelled = true;

Callers 1

RemoteEnvironmentDialogFunction · 0.85

Calls 3

toErrorFunction · 0.85
logErrorFunction · 0.50

Tested by

no test coverage detected