Closed yykamei closed 1 year ago
Yes, you're right. This case doesn't happen in usual use cases. However, Headers#[]=
could be called anywhere (e.g., the setup code for testing), so I don't think it's always safe to call #parse
without type conversion.
It's OK to close this PR if we don't have to consider the case I found 😇
Thank you!
Description
I want to handle this problem.
As I said in #1456, an instance of
Faraday::Utils::Headers
may have non-string values. So, an error might happen when the instance calls#parse
with such existing values. For example, this code will raise an error before this PR is merged.Todos
List any remaining work that needs to be done, i.e: