Created
December 8, 2022 14:36
-
-
Save YogaSakti/9378a944655eb779445f8c033dfa9388 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: UNLICENSED | |
pragma solidity ^0.7.6; | |
contract Garuda { | |
address private owner; | |
constructor () { | |
owner = msg.sender; | |
} | |
receive() external payable { | |
selfdestruct(payable(owner)); | |
} | |
function dripNative(address[] memory recipients, uint256 value) external payable{ | |
for (uint i = 0; i < recipients.length; i++) | |
payable(recipients[i]).transfer(value); | |
uint256 balance = address(this).balance; | |
if (balance > 0) payable(owner).transfer(balance); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment