40,000 USDC
View results
Submission Details
Severity: gas
Valid

Use assembly to check for zero address

Summary

Using assembly to check for address(0) saves gas.

There are 4 instances of this issue:

File: src/Escrow.sol
40: if (address(tokenContract) == address(0)) revert Escrow__TokenZeroAddress();
41: if (buyer == address(0)) revert Escrow__BuyerZeroAddress();
42: if (seller == address(0)) revert Escrow__SellerZeroAddress();
103: if (i_arbiter == address(0)) revert Escrow__DisputeRequiresArbiter();

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.