Chore: move catch into queries file

This commit is contained in:
csrapr 2021-02-15 13:50:54 +00:00 committed by Josh Harvey
parent 05373e83db
commit 82912b728a
7 changed files with 26 additions and 28 deletions

View file

@ -116,7 +116,7 @@ async function updateCustomer (id, data, userToken) {
const sql = Pgp.helpers.update(updateData, _.keys(updateData), 'customers') +
' where id=$1'
invalidateCustomerNotifications(id, formattedData).catch(console.error)
invalidateCustomerNotifications(id, formattedData)
await db.none(sql, [id])
@ -127,7 +127,7 @@ const invalidateCustomerNotifications = (id, data) => {
if (data.authorized_override !== 'verified') return Promise.resolve()
const detailB = notifierUtils.buildDetail({ code: 'BLOCKED', customerId: id })
return notifierQueries.invalidateNotification(detailB, 'compliance').catch(console.error)
return notifierQueries.invalidateNotification(detailB, 'compliance')
}
/**