From 6cbb989bbb87a787e392a3c3fab5296984ab0beb Mon Sep 17 00:00:00 2001 From: ericlee Date: Fri, 23 Feb 2024 10:43:30 +0800 Subject: [PATCH] perf(isContract): don't check zero address --- contracts/LockingPool.sol | 3 --- 1 file changed, 3 deletions(-) diff --git a/contracts/LockingPool.sol b/contracts/LockingPool.sol index fe27583..f5df10f 100644 --- a/contracts/LockingPool.sol +++ b/contracts/LockingPool.sol @@ -970,9 +970,6 @@ contract LockingPool is ILockingPool, OwnableUpgradeable, PausableUpgradeable { } function isContract(address _target) internal view returns (bool) { - if (_target == address(0)) { - return false; - } return _target.code.length > 0; }