-
Notifications
You must be signed in to change notification settings - Fork 11.9k
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
Assigning the ownership in the constructor creates issues for factory patterns #2402
Comments
I agree that using |
That is not exactly what you are asking for, but if you plan to have your contract inherit from |
Nice - that's also a much needed improvement but I would still request removing setting ownership in the constructor |
We've come to the following conclusion. We would have slightly preferred to have had the FWIW, the upcoming storage cost changes in the Berlin hard fork, if I'm reading them correctly, seem to drastically reduce the cost of the extra |
This creates additional 5k deployment cost to update the ownership as a part of the deployment. I recommend using an initializer function which accepts an arbitrary address as the owner.
openzeppelin-contracts/contracts/access/Ownable.sol
Lines 26 to 30 in ec8efd5
The text was updated successfully, but these errors were encountered: