I have the following function in my smart contract which fails to send funds to a Smart Contract Wallet (SCW). It works fine with standard accounts. I explicitly set gas to 0 because this is an internal transaction which does not consume gas.
Is there any alternative to replace .call method with a different one? How to properly send ether to SCW? I would appreciate if you could help me to fix the issue.
function sendEther (
address to,
uint256 amount
) private {
(bool sent, ) = payable(to).call{gas: 0, value: amount}("");
require(sent, "Could not send ether");
}