From 84535d40712259ff16b2d01c0e2c7b17f5b3be32 Mon Sep 17 00:00:00 2001 From: Joseph Izang Date: Mon, 24 Apr 2023 17:36:13 +0100 Subject: [PATCH] emit events on lint finished --- apps/solhint/src/app/SolhintPluginClient.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/solhint/src/app/SolhintPluginClient.ts b/apps/solhint/src/app/SolhintPluginClient.ts index 90a9ae5460..35c8d8f267 100644 --- a/apps/solhint/src/app/SolhintPluginClient.ts +++ b/apps/solhint/src/app/SolhintPluginClient.ts @@ -52,7 +52,7 @@ export class SolHint extends PluginClient { this.on('solidity', 'compilationFinished', async (fileName, source, languageVersion, data) => { const hints = await this.lint(fileName) console.log('after compile', { hints }) - this.eventEmitter.emit('lintOnCompilationFinished', hints) + this.emit('lintOnCompilationFinished', hints) }) this.triggerLinter = false } @@ -66,7 +66,7 @@ export class SolHint extends PluginClient { async lintContract(file: string) { const hints = await this.lint(file) console.log({ hints }) - this.eventEmitter.emit('lintingFinished', hints) + this.emit('lintingFinished', hints) } private async lint(fileName: string) {