Skip to content

Commit

Permalink
fix: remove wrong logic
Browse files Browse the repository at this point in the history
  • Loading branch information
sistemico committed Jul 17, 2021
1 parent 5c77a81 commit 22213a2
Showing 1 changed file with 0 additions and 25 deletions.
25 changes: 0 additions & 25 deletions src/mappings/registry.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,31 +48,6 @@ function getOrCreatePool(address: Address, event: ethereum.Event): Pool {
// Pool name
pool.name = registryContract.get_pool_name(address)

// Reference asset
let assetType = registryContract.try_get_pool_asset_type(address)

if (!assetType.reverted) {
let type = assetType.value.toString()

if (type == '0') {
pool.assetType = 'USD'
} else if (type == '1') {
pool.assetType = 'ETH'
} else if (type == '2') {
pool.assetType = 'BTC'
} else if (type == '3') {
if (pool.name == 'link') {
pool.assetType = 'LINK'
} else if (pool.name.startsWith('eur')) {
pool.assetType = 'EUR'
} else {
pool.assetType = 'OTHER'
}
} else if (type == '4') {
pool.assetType = 'CRYPTO'
}
}

// Coin balances and underlying coin balances/rates
saveCoins(pool!, event)

Expand Down

0 comments on commit 22213a2

Please sign in to comment.