fix build

This commit is contained in:
Yana
2025-03-24 12:48:21 +01:00
parent 752fe7fa0f
commit abeeadb661
2 changed files with 13 additions and 11 deletions
@@ -48,19 +48,11 @@ export const NodeProfileCard = ({ id }: INodeProfileCardProps) => {
refetchOnMount: false,
});
if (isError || !nymNodes) {
return (
<ExplorerCard label="Nym Node" sx={{ height: "100%" }}>
<Typography variant="h3" sx={{ color: "pine.950" }}>
Failed to load node data.
</Typography>
</ExplorerCard>
);
}
const nodeInfo = nymNodes.find((node) => node.node_id === id);
const nodeInfo = nymNodes?.find((node) => node.node_id === id);
const handleOnSelectStake = useCallback(() => {
if (!nodeInfo) return;
if (!isWalletConnected) {
setInfoModalProps({
open: true,
@@ -88,6 +80,16 @@ export const NodeProfileCard = ({ id }: INodeProfileCardProps) => {
}
}, [isWalletConnected, nodeInfo]);
if (isError || !nymNodes) {
return (
<ExplorerCard label="Nym Node" sx={{ height: "100%" }}>
<Typography variant="h3" sx={{ color: "pine.950" }}>
Failed to load node data.
</Typography>
</ExplorerCard>
);
}
if (isLoadingNymNodes) {
return (
<ExplorerCard label="Nym Node" sx={{ height: "100%" }}>
+1 -1
View File
@@ -3,7 +3,7 @@
import { getQueryClient } from "@/app/react-query";
import { QueryClientProvider } from "@tanstack/react-query";
import { ReactQueryDevtools } from "@tanstack/react-query-devtools";
import { type ReactNode, useState } from "react";
import { type ReactNode } from "react";
interface QueryProviderProps {
children: ReactNode;