Skip to content

Commit 733204c

Browse files
committed
fix: Add cachedNetwork to useMemo depencency
1 parent 2f6e2b1 commit 733204c

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • packages/neuron-ui/src/components/NetworkEditor

packages/neuron-ui/src/components/NetworkEditor/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ const NetworkEditor = ({
2121
const cachedNetwork = cachedNetworks.current.find(network => network.id === id)
2222
const usedNetworkNames = useMemo(
2323
() => networks.map(n => n.name).filter(name => name !== ((cachedNetwork && cachedNetwork.name) || '')),
24-
[networks]
24+
[networks, cachedNetwork]
2525
)
2626
const inputs = useInputs(editor, usedNetworkNames, t)
2727
const goBack = useGoBack(history)

0 commit comments

Comments
 (0)