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
the method HTTPHeadersParser::parse is not producing a valid headers array in some situations. If the response contains multiple headers with the same name (which happenend to me with "set-cookie") an awkward nested array is created in this line:
So if you have more than two "set-cookie" headers you would end up with a multiple nested array which cannot be handled by symfonys Cookie::fromString($cookie) method (explode will fail and cause exception).
I fixed it by writing my own global "http_parse_headers" function, replacing the line above with this:
Hello,
the method HTTPHeadersParser::parse is not producing a valid headers array in some situations. If the response contains multiple headers with the same name (which happenend to me with "set-cookie") an awkward nested array is created in this line:
$carry[$match[1]] = isset($carry[$match[1]]) ? [$carry[$match[1]], $match[2]] : trim($match[2]);
So if you have more than two "set-cookie" headers you would end up with a multiple nested array which cannot be handled by symfonys
Cookie::fromString($cookie)
method (explode will fail and cause exception).I fixed it by writing my own global "http_parse_headers" function, replacing the line above with this:
Greetings!
The text was updated successfully, but these errors were encountered: