Skip to content

Commit

Permalink
Merge pull request #89 from 0xIntuition/improved-atomwallet-time-vali…
Browse files Browse the repository at this point in the history
…dation

improve condition check for AtomWallet time validation
  • Loading branch information
mihailo-maksa authored Jul 14, 2024
2 parents b2789de + 21c7fe6 commit d0c0462
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/AtomWallet.sol
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,8 @@ contract AtomWallet is Initializable, BaseAccount, Ownable2StepUpgradeable, Reen
{
(uint256 validUntil, uint256 validAfter,) = extractValidUntilAndValidAfter(userOp.callData);

if (block.timestamp < validAfter || block.timestamp > validUntil) {
// validUntil can be 0, meaning there won't be an expiration
if (block.timestamp <= validAfter || (block.timestamp >= validUntil && validUntil != 0)) {
return SIG_VALIDATION_FAILED;
}

Expand Down

0 comments on commit d0c0462

Please sign in to comment.