fixed default values for token contracts that already mint when bought
This commit is contained in:
parent
d67e67d166
commit
b2b513bf01
1 changed files with 2 additions and 2 deletions
4
core.py
4
core.py
|
|
@ -226,7 +226,8 @@ def convert_tokens_multi(account, multi_address, token0_address, token1_address,
|
||||||
|
|
||||||
# get the cost required to convert tokens
|
# get the cost required to convert tokens
|
||||||
cost = routes_functions[multi_address]['costs'][token0_address]
|
cost = routes_functions[multi_address]['costs'][token0_address]
|
||||||
tokens_cost = cost * iterations * routes_functions[multi_address]['mints']
|
mints = routes_functions[multi_address]['mints'] or 1
|
||||||
|
tokens_cost = cost * iterations * mints
|
||||||
# python is so stupid sometimes
|
# python is so stupid sometimes
|
||||||
try:
|
try:
|
||||||
decimal_places = len(str(cost).split('.')[1])
|
decimal_places = len(str(cost).split('.')[1])
|
||||||
|
|
@ -757,4 +758,3 @@ def wrap_pls(account, amount, attempts=18):
|
||||||
if error := interpret_exception_message(e):
|
if error := interpret_exception_message(e):
|
||||||
logging.error("{} to wrap PLS".format(error))
|
logging.error("{} to wrap PLS".format(error))
|
||||||
return False
|
return False
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue