Skip to content

Commit

Permalink
rm override if higher
Browse files Browse the repository at this point in the history
  • Loading branch information
aroralanuk committed Dec 13, 2024
1 parent d996b3a commit 4f04099
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 27 deletions.
5 changes: 0 additions & 5 deletions .changeset/long-llamas-fly.md

This file was deleted.

22 changes: 0 additions & 22 deletions solidity/contracts/hooks/libs/StandardHookMetadata.sol
Original file line number Diff line number Diff line change
Expand Up @@ -184,26 +184,4 @@ library StandardHookMetadata {
getCustomMetadata(_metadata)
);
}

/**
* @notice Overrides the gas limit in the metadata if _gasLimit is higher than the current gas limit.
* @param _metadata encoded standard hook metadata.
* @param _gasLimit gas limit for the message.
* @return encoded standard hook metadata.
*/
function overrideGasLimit(
bytes calldata _metadata,
uint256 _gasLimit
) internal view returns (bytes memory) {
if (gasLimit(_metadata, 0) < _gasLimit) {
return
formatMetadata(
msgValue(_metadata, 0),
_gasLimit,
refundAddress(_metadata, msg.sender),
getCustomMetadata(_metadata)
);
}
return _metadata;
}
}

0 comments on commit 4f04099

Please sign in to comment.