mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
token-util - warn via loglevel on token lookup failure
This commit is contained in:
parent
708422432c
commit
666c1f1b30
@ -1,3 +1,4 @@
|
|||||||
|
const log = require('loglevel')
|
||||||
const util = require('./util')
|
const util = require('./util')
|
||||||
|
|
||||||
function tokenInfoGetter () {
|
function tokenInfoGetter () {
|
||||||
@ -29,7 +30,7 @@ async function getSymbolAndDecimals (tokenAddress, existingTokens = []) {
|
|||||||
token.decimals(),
|
token.decimals(),
|
||||||
])
|
])
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
console.log(`symbol() and decimal() calls for token at address ${tokenAddress} resulted in error:`, err)
|
log.warn(`symbol() and decimal() calls for token at address ${tokenAddress} resulted in error:`, err)
|
||||||
}
|
}
|
||||||
|
|
||||||
const [ symbol = [], decimals = [] ] = result
|
const [ symbol = [], decimals = [] ] = result
|
||||||
|
Loading…
Reference in New Issue
Block a user