make normal relayer's fee

This commit is contained in:
Roman Storm 2019-11-26 12:34:52 -08:00
parent 1edc8ff69c
commit ffb9043b60
3 changed files with 4 additions and 4 deletions

View file

@ -58,7 +58,7 @@ function sleep(ms) {
function isEnoughFee({ gas, gasPrices, currency, amount, refund, ethPrices, fee }) {
// TODO tokens can have less then 18 decimals
const feePercent = toBN(toWei(amount)).mul(toBN(relayerServiceFee)).div(toBN('1000'))
const feePercent = toBN(toWei(amount)).mul(toBN(Number(relayerServiceFee) * 10)).div(toBN('1000'))
const expense = toBN(toWei(gasPrices.fast.toString(), 'gwei')).mul(toBN(gas))
let desiredFee
switch (currency) {