chore: dont report known errors

pull/115/head
Amio 2018-08-16 15:58:09 +08:00
rodzic e63fa9043a
commit 0de192d443
1 zmienionych plików z 3 dodań i 4 usunięć

Wyświetl plik

@ -30,12 +30,11 @@ module.exports = async (scope, fn, paramsPath) => {
}
const errorLogger = (fetchKey, err, status) => {
try {
if (status === 'unknown') {
raven.captureException(err, {
tags: { fetchKey, status, service: fetchKey.split(' ')[0] }
})
try {
if (status === 'unknown') {
// log details err info
const resData = JSON.stringify(err.response.data, null, 2)
const details = err.stack + '\n' + resData.replace(/^/mg, ' > ')