This commit is contained in:
poma 2021-08-19 13:21:48 +03:00
parent 7fc3e37eb0
commit 0a515b06aa
No known key found for this signature in database
GPG Key ID: BA20CB01FE165657

View File

@ -113,7 +113,7 @@ contract TornadoPool {
} }
} }
function calculatePublicAmount(int256 _extAmount, uint256 _fee) public pure returns(uint256) { function calculatePublicAmount(int256 _extAmount, uint256 _fee) public pure returns (uint256) {
require(_fee < MAX_FEE, "Invalid fee"); require(_fee < MAX_FEE, "Invalid fee");
require(_extAmount > -MAX_EXT_AMOUNT && _extAmount < MAX_EXT_AMOUNT, "Invalid ext amount"); require(_extAmount > -MAX_EXT_AMOUNT && _extAmount < MAX_EXT_AMOUNT, "Invalid ext amount");
int256 publicAmount = _extAmount - int256(_fee); int256 publicAmount = _extAmount - int256(_fee);