From 568369a8f18b4670620023851452c5fdebaaa5a0 Mon Sep 17 00:00:00 2001 From: Kelvin Fichter Date: Thu, 17 Jun 2021 14:27:38 -0400 Subject: [PATCH] lint: fix --- packages/smock/src/smockit/binding.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/packages/smock/src/smockit/binding.ts b/packages/smock/src/smockit/binding.ts index a0416526552e..1779d85bc985 100644 --- a/packages/smock/src/smockit/binding.ts +++ b/packages/smock/src/smockit/binding.ts @@ -3,6 +3,7 @@ import { HardhatNetworkProvider } from 'hardhat/internal/hardhat-network/provide import { VmError } from '@nomiclabs/ethereumjs-vm/dist/exceptions' import BN from 'bn.js' +/* eslint-disable @typescript-eslint/no-var-requires */ // Handle hardhat ^2.4.0 let decodeRevertReason: (value: Buffer) => string try { @@ -16,18 +17,16 @@ try { return new ReturnData(value).decodeError() } } - // Handle hardhat ^2.2.0 let TransactionExecutionError: any try { - // eslint-disable-next-line @typescript-eslint/no-var-requires TransactionExecutionError = require('hardhat/internal/hardhat-network/provider/errors') .TransactionExecutionError } catch (err) { - // eslint-disable-next-line @typescript-eslint/no-var-requires TransactionExecutionError = require('hardhat/internal/core/providers/errors') .TransactionExecutionError } +/* eslint-enable @typescript-eslint/no-var-requires */ /* Imports: Internal */ import { MockContract, SmockedVM } from './types'