You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Basically, the local variable header is the value of the content-type header, so trying to use it as the index into the headers array is incorrect -- and returns an undefined object, which you can't call .split() on.
Seems like the correct fix is to just call header.split() directly?
The text was updated successfully, but these errors were encountered:
If one specifies a
Content-Type
header, an unhandled exception will be thrown from here:https://github.com/Mashape/unirest-nodejs/blob/master/index.js#L527
Basically, the local variable
header
is the value of the content-type header, so trying to use it as the index into the headers array is incorrect -- and returns an undefined object, which you can't call.split()
on.Seems like the correct fix is to just call
header.split()
directly?The text was updated successfully, but these errors were encountered: