Skip to content

Commit

Permalink
fix-lint
Browse files Browse the repository at this point in the history
  • Loading branch information
ShivaanshK committed Jul 10, 2024
1 parent ebf05c1 commit 36d854b
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions contracts/base/BasePaymaster.sol
Original file line number Diff line number Diff line change
Expand Up @@ -103,14 +103,6 @@ abstract contract BasePaymaster is IPaymaster, SoladyOwnable {
return entryPoint.balanceOf(address(this));
}

function isContract(address _addr) internal view returns (bool) {
uint256 size;
assembly ("memory-safe") {
size := extcodesize(_addr)
}
return size > 0;
}

//sanity check: make sure this EntryPoint was compiled against the same
// IEntryPoint of this paymaster
function _validateEntryPointInterface(IEntryPoint _entryPoint) internal virtual {
Expand Down Expand Up @@ -170,4 +162,12 @@ abstract contract BasePaymaster is IPaymaster, SoladyOwnable {
function _requireFromEntryPoint() internal virtual {
require(msg.sender == address(entryPoint), "Sender not EntryPoint");
}

function isContract(address _addr) internal view returns (bool) {
uint256 size;
assembly ("memory-safe") {
size := extcodesize(_addr)
}
return size > 0;
}
}

0 comments on commit 36d854b

Please sign in to comment.