Skip to content

Commit

Permalink
feat(timestamp): getter for block timestamp
Browse files Browse the repository at this point in the history
  • Loading branch information
rharutyunyan committed Nov 14, 2023
1 parent a9c78c6 commit 42ac012
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions contracts/MultiCall.sol
Original file line number Diff line number Diff line change
Expand Up @@ -73,4 +73,10 @@ contract MultiCall {
function gasLeft() external view returns (uint256) {
return gasleft();
}

/// @notice Fetches the block timestamp.
/// @return result timestamp of the block.
function getCurrentBlockTimestamp() external view returns (uint256) {
return block.timestamp;

Check warning on line 80 in contracts/MultiCall.sol

View workflow job for this annotation

GitHub Actions / lint

Avoid making time-based decisions in your business logic
}
}

0 comments on commit 42ac012

Please sign in to comment.