Skip to content

Commit

Permalink
Merge pull request #155 from karlhorky/patch-1
Browse files Browse the repository at this point in the history
Return error to callback
  • Loading branch information
hedyyytang authored Jul 21, 2022
2 parents 343276a + 6a4bd7c commit 4491648
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/vimeo.js
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ Vimeo.prototype._handleRequest = function (callback) {
try {
var body = buffer.length ? JSON.parse(buffer) : {}
} catch (e) {
return callback(buffer, buffer, res.statusCode, res.headers)
return callback(e, buffer, res.statusCode, res.headers)
}

callback(null, body, res.statusCode, res.headers)
Expand Down

0 comments on commit 4491648

Please sign in to comment.