diff --git a/libs/remix-ui/terminal/src/lib/actions/terminalAction.ts b/libs/remix-ui/terminal/src/lib/actions/terminalAction.ts index dafe6f78cf..d0efd289b5 100644 --- a/libs/remix-ui/terminal/src/lib/actions/terminalAction.ts +++ b/libs/remix-ui/terminal/src/lib/actions/terminalAction.ts @@ -106,8 +106,8 @@ export const registerErrorScriptRunnerAction = (on, commandName, commandFn, disp }) } -export const listenOnNetworkAction = async (event, isListening) => { - event.trigger('listenOnNetWork', [isListening]) +export const listenOnNetworkAction = async (plugins, isListening) => { + plugins.txListener.setListenOnNetwork(isListening) } export const initListeningOnNetwork = (plugins, dispatch: React.Dispatch) => { diff --git a/libs/remix-ui/terminal/src/lib/remix-ui-terminal.tsx b/libs/remix-ui/terminal/src/lib/remix-ui-terminal.tsx index a0f6b26ad7..8e9dfb21e9 100644 --- a/libs/remix-ui/terminal/src/lib/remix-ui-terminal.tsx +++ b/libs/remix-ui/terminal/src/lib/remix-ui-terminal.tsx @@ -316,7 +316,7 @@ export const RemixUiTerminal = (props: RemixUiTerminalProps) => { const listenOnNetwork = (e: any) => { const isListening = e.target.checked // setIsListeningOnNetwork(isListening) - listenOnNetworkAction(event, isListening) + listenOnNetworkAction(props.plugin, isListening) } const onChange = (event: any) => {