Using _setURI directly instead of the initializer __ERC1155_init risks potential compatibility issues. It is best practice to use the __ERC1155_init function for better upgrade support.
In the initialize function of MembershipERC1155, the _setURI function is called directly:
This approach bypasses the recommended initializer function, __ERC1155_init, from the ERC1155Upgradeable contract:
Utilizing __ERC1155_init ensures compatibility with potential updates in the ERC1155 contract, making it a best practice for upgradable contracts.
Failing to use the initializer function can lead to inconsistent behavior or compatibility issues with future upgrades of ERC1155.
Manual
Invoke __ERC1155_init instead of directly calling _setURI in MembershipERC1155 to maintain compatibility with future contract updates.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.