reset only if remixd is deactivated

pull/1412/head
lianahus 3 years ago committed by Aniket
parent f2df1daad9
commit 6a7c8e223c
  1. 4
      libs/remix-ui/static-analyser/src/lib/remix-ui-static-analyser.tsx

@ -95,14 +95,14 @@ export const RemixUiStaticAnalyser = (props: RemixUiStaticAnalyserProps) => {
} }
}) })
props.analysisModule.on('manager', 'pluginDeactivated', (plugin) => { props.analysisModule.on('manager', 'pluginDeactivated', (plugin) => {
// Hide 'Enable Slither Analysis' checkbox
if (plugin.name === 'remixd') {
// Reset warning state // Reset warning state
setWarningState([]) setWarningState([])
// Reset badge // Reset badge
props.event.trigger('staticAnaysisWarning', []) props.event.trigger('staticAnaysisWarning', [])
// Reset state // Reset state
dispatch({ type: '', payload: {} }) dispatch({ type: '', payload: {} })
// Hide 'Enable Slither Analysis' checkbox
if (plugin.name === 'remixd') {
setShowSlither('hidden') setShowSlither('hidden')
setSlitherEnabled(false) setSlitherEnabled(false)
} }

Loading…
Cancel
Save