Skip to content

Commit 5abb2ea

Browse files
committed
use proper way to send eth
1 parent 795ffa8 commit 5abb2ea

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

contracts/communityFee/OPFCommunityFeeCollector.sol

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,8 @@ contract OPFCommunityFeeCollector is Ownable {
6060
external
6161
payable
6262
{
63-
collector.transfer(address(this).balance);
63+
(bool sent, ) = collector.call{value: address(this).balance}("");
64+
require(sent, "Failed to send Ether");
6465
}
6566

6667
/**

0 commit comments

Comments
 (0)