Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix HTTP client config handling #35553

Merged
merged 1 commit into from Feb 4, 2020
Merged

Conversation

julienfalque
Copy link
Contributor

Q A
Branch? 4.4
Bug fix? yes
New feature? no
Deprecations? no
Tickets -
License MIT
Doc PR -

Defining a key parameter in the query option of a scoped HTTP client triggers an error:

Undefined index: value

This PR fixes this issue but an edge case still remains with YAML and PHP config. If one wants to define parameters key=foo, value=bar and nothing else, the query will actually be foo=bar instead of key=foo&value=bar. Not sure how to fix this case without breaking the tests I added here.

@nicolas-grekas nicolas-grekas added this to the 4.4 milestone Feb 1, 2020
@nicolas-grekas
Copy link
Member

This LGTM but I'd be happy to have your confirmation @stof please.

@fabpot
Copy link
Member

fabpot commented Feb 4, 2020

Thank you @julienfalque.

fabpot added a commit that referenced this pull request Feb 4, 2020
This PR was merged into the 4.4 branch.

Discussion
----------

Fix HTTP client config handling

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | -
| License       | MIT
| Doc PR        | -

Defining a `key` parameter in the `query` option of a scoped HTTP client triggers an error:
```
Undefined index: value
```
This PR fixes this issue but an edge case still remains with YAML and PHP config. If one wants to define parameters `key=foo`, `value=bar` and nothing else, the query will actually be `foo=bar` instead of `key=foo&value=bar`. Not sure how to fix this case without breaking the tests I added here.

Commits
-------

963d0cc Fix HTTP client config handling
@fabpot fabpot merged commit 963d0cc into symfony:4.4 Feb 4, 2020
@julienfalque julienfalque deleted the fix-undefined-value branch February 4, 2020 10:44
This was referenced Feb 29, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants