Skip to content

Commit

Permalink
bugfix always add native wrapped gas infor to the token objects
Browse files Browse the repository at this point in the history
  • Loading branch information
NIXBNT authored and platonfloria committed May 9, 2024
1 parent da689f0 commit 93ed201
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions fastlane_bot/events/interface.py
Original file line number Diff line number Diff line change
Expand Up @@ -509,11 +509,11 @@ def populate_tokens(self):
self.token_list[token.address] = token
except AttributeError:
pass
if self.ConfigObj.GAS_TKN_IN_FLASHLOAN_TOKENS:
native_gas_tkn = Token(symbol=self.ConfigObj.NATIVE_GAS_TOKEN_SYMBOL, address=self.ConfigObj.NATIVE_GAS_TOKEN_ADDRESS, decimals=18)
wrapped_gas_tkn = Token(symbol=self.ConfigObj.WRAPPED_GAS_TOKEN_SYMBOL, address=self.ConfigObj.WRAPPED_GAS_TOKEN_ADDRESS, decimals=18)
self.token_list[native_gas_tkn.address] = native_gas_tkn
self.token_list[wrapped_gas_tkn.address] = wrapped_gas_tkn
# native and wrapped gas token info populated everytime
native_gas_tkn = Token(symbol=self.ConfigObj.NATIVE_GAS_TOKEN_SYMBOL, address=self.ConfigObj.NATIVE_GAS_TOKEN_ADDRESS, decimals=18)
wrapped_gas_tkn = Token(symbol=self.ConfigObj.WRAPPED_GAS_TOKEN_SYMBOL, address=self.ConfigObj.WRAPPED_GAS_TOKEN_ADDRESS, decimals=18)
self.token_list[native_gas_tkn.address] = native_gas_tkn
self.token_list[wrapped_gas_tkn.address] = wrapped_gas_tkn

def create_token(self, record: Dict[str, Any], prefix: str) -> Token:
"""
Expand Down

0 comments on commit 93ed201

Please sign in to comment.