Skip to content

Commit

Permalink
fix(loggin): do not throw error when creating log file
Browse files Browse the repository at this point in the history
  • Loading branch information
Khaledgarbaya committed Jan 19, 2018
1 parent a132978 commit d0e9de1
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions lib/utils/logging.js
Original file line number Diff line number Diff line change
Expand Up @@ -119,11 +119,9 @@ export function writeErrorLogFile (destination, errorLog) {
console.log('\nStored the detailed error log file at:')
console.log(destination)
})
.then(() => {
const multiError = new Error('Errors occured')
multiError.name = 'ContentfulMultiError'
multiError.errors = errorLog
throw multiError
.catch((e) => {
// avoid craching when writing the log file fails
console.error(e)
})
}

Expand Down

0 comments on commit d0e9de1

Please sign in to comment.