contract MyContract {
address payable[] recipients;
function sendEther(address payable recipient) external payable {
recipient.transfer(1 ether);
}
}
Error- transact to MyContract.sendEther errored: VM error: revert. revert The transaction has been reverted to the initial state. Note: The called function should be payable if you send value and the value you send should be less than your current balance.