-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Check the order of parameters in the constructor of a contract when using buildModule. #741
Comments
That is interesting. I don't think we would change passing args as an array to say an object with named properties matching the Solidity function parameter names. Currently our |
Just one idea: perhaps it could have a method that takes a correctly typed object and returns the arguments array in the correct order. Like:
So, in the example above, the object used to construct the arguments should be correctly typed and include all the arguments specified in the contract. |
Sorry, I accidentally closed the issue. :( |
A helper function on top of the Module API would work. |
I can try submitting a pull request. |
Sometimes a contract has multiple parameters in its constructor. It's easy to accidentally swap the order of these parameters.
Does Hardhat Ignition currently offer the functionality to display parameter names, or both names and types?
If not, is it feasible to extract that information from the contract when using Hardhat Ignition?
Just to illustrate, in the example below, we might swap the 'name/symbol' or the 'owner/feeRecipient' parameters:
The text was updated successfully, but these errors were encountered: