Commit 577943ea authored by aniket-engg's avatar aniket-engg

check if hardhat is active before deactivating

parent 4532a3b8
...@@ -40,7 +40,7 @@ export class RemixdHandle extends WebsocketPlugin { ...@@ -40,7 +40,7 @@ export class RemixdHandle extends WebsocketPlugin {
deactivate () { deactivate () {
if (super.socket) super.deactivate() if (super.socket) super.deactivate()
// this.appManager.deactivatePlugin('git') // plugin call doesn't work.. see issue https://github.com/ethereum/remix-plugin/issues/342 // this.appManager.deactivatePlugin('git') // plugin call doesn't work.. see issue https://github.com/ethereum/remix-plugin/issues/342
this.appManager.deactivatePlugin('hardhat') if (this.appManager.actives.includes('hardhat')) this.appManager.deactivatePlugin('hardhat')
this.locahostProvider.close((error) => { this.locahostProvider.close((error) => {
if (error) console.log(error) if (error) console.log(error)
}) })
......
...@@ -53,8 +53,6 @@ export class RemixAppManager extends PluginManager { ...@@ -53,8 +53,6 @@ export class RemixAppManager extends PluginManager {
} }
async deactivatePlugin (name) { async deactivatePlugin (name) {
const isActive = await this.isActive(name)
if (!isActive) return
const [to, from] = [ const [to, from] = [
await this.getProfile(name), await this.getProfile(name),
await this.getProfile(this.requestFrom) await this.getProfile(this.requestFrom)
......
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