I added mint function to safemoon but when I mint, I get error.
Code to reproduce
This is my code.
function _mint(address account, uint256 amount) internal {
require(account != address(0), "BEP20: mint to the zero address");
uint256 currentRate = _getRate();
uint256 rAmount = amount.mul(currentRate);
_rOwned[account] = _rOwned[account].add(rAmount);
_tTotal = _tTotal.add(amount);
_rTotal = _rTotal.add(rAmount);
emit Transfer(address(0), account, amount);
}
plz give me advice.
Environment
Remix IDE