kopia lustrzana https://github.com/bugout-dev/moonstream
clear comments and lint
rodzic
b102f4eeb6
commit
8749ec0e33
|
@ -62,7 +62,6 @@ const Subscriptions = () => {
|
||||||
<Center>
|
<Center>
|
||||||
<Spinner
|
<Spinner
|
||||||
hidden={false}
|
hidden={false}
|
||||||
// ref={loadMoreButtonRef}
|
|
||||||
my={8}
|
my={8}
|
||||||
size="lg"
|
size="lg"
|
||||||
color="primary.500"
|
color="primary.500"
|
||||||
|
|
|
@ -10,13 +10,21 @@ const useTxInfo = (transaction) => {
|
||||||
return response.data;
|
return response.data;
|
||||||
};
|
};
|
||||||
const { data, isLoading, isFetchedAfterMount, refetch, isError, error } =
|
const { data, isLoading, isFetchedAfterMount, refetch, isError, error } =
|
||||||
useQuery(["txinfo", (transaction.tx && transaction.tx.hash)], getTxInfo, {
|
useQuery(["txinfo", transaction.tx && transaction.tx.hash], getTxInfo, {
|
||||||
...queryCacheProps,
|
...queryCacheProps,
|
||||||
enabled: !!transaction.tx,
|
enabled: !!transaction.tx,
|
||||||
onError: (error) => toast(error, "error"),
|
onError: (error) => toast(error, "error"),
|
||||||
});
|
});
|
||||||
const isFetching = !!transaction.tx;
|
const isFetching = !!transaction.tx;
|
||||||
return { data, isFetchedAfterMount, isLoading, refetch, isFetching, isError, error };
|
return {
|
||||||
|
data,
|
||||||
|
isFetchedAfterMount,
|
||||||
|
isLoading,
|
||||||
|
refetch,
|
||||||
|
isFetching,
|
||||||
|
isError,
|
||||||
|
error,
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
export default useTxInfo;
|
export default useTxInfo;
|
||||||
|
|
Ładowanie…
Reference in New Issue