At firstly State not set to Created by the buyer when there is no state created not any Action perform so in constructor we need to update the stare as created.
there is no initial state update in the contract without this con't perform any operations so we need to update it in the constructor it indicates that when the Escrow is created then State is Also Created.
Not perform any Actions without Any state is created. In all functions they checked that when the state is created then only perform Actions But buyer Con't initial it any where so they con't Perform any Actions
Manual Review
update the State value in constructor
constructor(
uint256 price,
IERC20 tokenContract,
address buyer,
address seller,
address arbiter,
uint256 arbiterFee
) {
if (address(tokenContract) == address(0)) revert Escrow__TokenZeroAddress();
if (buyer == address(0)) revert Escrow__BuyerZeroAddress();
if (seller == address(0)) revert Escrow__SellerZeroAddress();
if (arbiterFee >= price) revert Escrow__FeeExceedsPrice(price, arbiterFee);
if (tokenContract.balanceOf(address(this)) < price) revert Escrow__MustDeployWithTokenBalance();
i_price = price;
i_tokenContract = tokenContract;
i_buyer = buyer;
i_seller = seller;
i_arbiter = arbiter;
i_arbiterFee = arbiterFee;
++ s_state = State.Created;
}
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.