Skip to content

Commit

Permalink
Add USDT as supported CryptoCurrency
Browse files Browse the repository at this point in the history
  • Loading branch information
sisou committed Oct 18, 2024
1 parent 5838ddf commit 378344f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions src/fiat-api/FiatApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ export enum CryptoCurrency {
BTC = 'btc',
ETH = 'eth',
USDC = 'usdc',
USDT = 'usdt',
}

// This enum has been generated from the generated lists CRYPTOCOMPARE_FIAT_CURRENCIES, COINGECKO_FIAT_CURRENCIES and
Expand Down Expand Up @@ -404,6 +405,7 @@ const COIN_IDS_COINGECKO = {
[CryptoCurrency.BTC]: 'bitcoin',
[CryptoCurrency.ETH]: 'ethereum',
[CryptoCurrency.USDC]: 'usd-coin',
[CryptoCurrency.USDT]: 'tether',
} as const;

const ONE_SECOND = 1000;
Expand Down
2 changes: 1 addition & 1 deletion tests/CurrencyInfo.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ describe('CurrencyInfo', () => {
});

it('can generate names for different locales', () => {
const possibleLanguages = [];
const possibleLanguages: string[] = [];
for (let char1 = 'a'.charCodeAt(0); char1 <= 'z'.charCodeAt(0); ++char1) {
for (let char2 = 'a'.charCodeAt(0); char2 <= 'z'.charCodeAt(0); ++char2) {
possibleLanguages.push(`${String.fromCharCode(char1)}${String.fromCharCode(char2)}`);
Expand Down

0 comments on commit 378344f

Please sign in to comment.