Commit 62747b5f authored by aniket-engg's avatar aniket-engg Committed by Aniket

hardhat compilation with error and result fixed

parent 71d676e4
...@@ -37,10 +37,11 @@ export class HardhatClient extends PluginClient { ...@@ -37,10 +37,11 @@ export class HardhatClient extends PluginClient {
result += msg + '\n' result += msg + '\n'
}) })
child.stderr.on('data', (err) => { child.stderr.on('data', (err) => {
error += `[Hardhat Compilation]: ${err.toString()}` error += `[Hardhat Compilation]: ${err.toString()} \n`
}) })
child.on('close', () => { child.on('close', () => {
if (error) reject(error) if (error && result) resolve(error + result)
else if (error) reject(error)
else resolve(result) else resolve(result)
}) })
}) })
......
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