Lista di cryptovalute (#36)
* CryptoSymbolsTool per recuperare TUTTI i simboli delle criptovalute da Yahoo Finance * CryptoSymbolsTools integrazione nel sistema di strumenti. * Removed currency from config * fix format symbol in all markets
This commit was merged in pull request #36.
This commit is contained in:
committed by
GitHub
parent
12339ccbff
commit
2e092d3f25
@@ -61,7 +61,9 @@ class CoinBaseWrapper(MarketWrapper):
|
||||
)
|
||||
|
||||
def __format(self, asset_id: str) -> str:
|
||||
return asset_id if '-' in asset_id else f"{asset_id}-{self.currency}"
|
||||
i = asset_id.find('-')
|
||||
if i != -1: asset_id = asset_id[:i]
|
||||
return f"{asset_id}-{self.currency}"
|
||||
|
||||
def get_product(self, asset_id: str) -> ProductInfo:
|
||||
asset_id = self.__format(asset_id)
|
||||
|
||||
Reference in New Issue
Block a user