Skip to content

Commit

Permalink
[utils] better content type error
Browse files Browse the repository at this point in the history
  • Loading branch information
nleush committed Feb 24, 2017
1 parent eeed23a commit 4bceb0c
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lib/plugins/validators/async/21_checkFlash.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,11 @@ module.exports = {

var error = error || (data && data.error);

if (error && error.reason) {
// Compact error if 'reason' available.
error = error.reason;
}

if (error) {
// Unknown error.
link.error = error;
Expand Down

0 comments on commit 4bceb0c

Please sign in to comment.