requestRefund
solidity
function requestRefund(uint256 id) externalOnly the client can call this function, and the escrow must remain Funded.
The deadline check is:
solidity
if (block.timestamp <= escrow.deadline) revert DeadlineNotPassed();Therefore the call is valid only when:
text
block.timestamp > deadlineThe full escrow amount is transferred directly back to the client, status becomes Refunded, and Refunded(id, amount) is emitted.
Reverts
NotClient()InvalidStatus(current, Funded)DeadlineNotPassed()TransferFailed()