I encountered a TypeError in the code while trying to invoke a modifier in the flashloan.sol contract. The error message suggests an invalid type for the argument in the modifier invocation, specifically an invalid implicit conversion from contract IPoolAddressesProvider to contract IPoolAddressesProvider is being requested.
Steps to Reproduce:
Deploy the contract with the given code.
Attempt to invoke the modifier in the flashloan.sol contract.
Observe the TypeError mentioned in the error message.
Expected Behavior:
The code should compile without any errors, and the modifier should be invoked successfully without type conversion issues.
Actual Behavior:
Encountered a TypeError with the following details:
TypeError: Invalid type for argument in modifier invocation. Invalid implicit conversion from contract IPoolAddressesProvider to contract IPoolAddressesProvider requested.
--> contracts/flashloan.sol:13:35:
|
13 | ) FlashLoanSimpleReceiverBase(IPoolAddressesProvider(_addressProvider)) {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Environment:
Solidity Compiler version: "0.8.10"
Operating system: Windows x64
I also tried fixing the code with Remix Ide also, after spending times fixing it on local using Hardhat but no results unfortunately, please let me know how it can be fixed thanks!
Issue Summary:
I encountered a
TypeError
in the code while trying to invoke a modifier in theflashloan.sol
contract. The error message suggests an invalid type for the argument in the modifier invocation, specifically an invalid implicit conversion from contractIPoolAddressesProvider
to contractIPoolAddressesProvider
is being requested.Steps to Reproduce:
flashloan.sol
contract.TypeError
mentioned in the error message.Expected Behavior:
The code should compile without any errors, and the modifier should be invoked successfully without type conversion issues.
Actual Behavior:
Encountered a
TypeError
with the following details:Environment:
I also tried fixing the code with
Remix Ide
also, after spending times fixing it on local usingHardhat
but no results unfortunately, please let me know how it can be fixed thanks!