Ignore specific warnings and make the rest into errors (#3695)

This commit is contained in:
Francisco
2022-09-22 17:33:13 -03:00
committed by GitHub
parent 06e678d6ef
commit 046121e080
7 changed files with 490 additions and 58 deletions

View File

@ -106,9 +106,13 @@ abstract contract ERC721Enumerable is ERC721, IERC721Enumerable {
address,
address,
uint256,
uint96
uint96 size
) internal virtual override {
revert("ERC721Enumerable: consecutive transfers not supported");
// We revert because enumerability is not supported with consecutive batch minting.
// This conditional is only needed to silence spurious warnings about unreachable code.
if (size > 0) {
revert("ERC721Enumerable: consecutive transfers not supported");
}
}
/**