Commit ad44e1ec authored by aniket-engg's avatar aniket-engg Committed by Aniket

check if remixd activated before switching

parent f8be36a5
...@@ -272,11 +272,13 @@ export const Workspace = (props: WorkspaceProps) => { ...@@ -272,11 +272,13 @@ export const Workspace = (props: WorkspaceProps) => {
const remixdExplorer = { const remixdExplorer = {
hide: async () => { hide: async () => {
if (props.fileManager.mode === 'localhost') {
await setWorkspace(NO_WORKSPACE) await setWorkspace(NO_WORKSPACE)
props.fileManager.setMode('browser') props.fileManager.setMode('browser')
setState(prevState => { setState(prevState => {
return { ...prevState, hideRemixdExplorer: true, loadingLocalhost: false } return { ...prevState, hideRemixdExplorer: true, loadingLocalhost: false }
}) })
}
}, },
show: () => { show: () => {
props.fileManager.setMode('localhost') props.fileManager.setMode('localhost')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment