1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-23 09:52:26 +01:00

Remove redundant error logging (#7158)

The `_fetchAll` function is expected to return values, so catching
errors and logging them only results in an additional error at the
place where `_fetchAll` is called. It's better instead to let the
error get thrown as normal.

In this particular case `_fetchAll` is only called in once place. The
error is still correctly caught and logged (in the `_update` function)
This commit is contained in:
Mark Stacey 2019-09-12 17:00:35 -03:00 committed by GitHub
parent 34440d63eb
commit a00493fdbd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -171,12 +171,8 @@ class IncomingTransactionsController {
}
async _fetchAll (address, fromBlock, networkType) {
try {
const fetchedTxResponse = await this._fetchTxs(address, fromBlock, networkType)
return this._processTxFetchResponse(fetchedTxResponse)
} catch (err) {
log.error(err)
}
}
async _fetchTxs (address, fromBlock, networkType) {