Skip to content

Add QueryStringToArray Filter #168

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

Merged
merged 1 commit into from
Dec 27, 2023

Conversation

charjr
Copy link
Collaborator

@charjr charjr commented Dec 22, 2023

This filter

  1. explodes on & into segments.

  2. explodes each value on = into pairs.

  3. inserts each pair as a key-value pair into an array (without overwriting)

The result is an array<string,string[]>

See the test for example outputs.

What this does is handle collecting the data together based on properties, after which it will still need to handle the style elsewhere. This can be added to the beforeSet for query parameters, something in each field processor will need to handle individual styles.

A combination of differing styles and explodes should not cause issue referring to this:
OAI/OpenAPI-Specification#1508

@carnage carnage merged commit 78acf18 into membrane-php:main Dec 27, 2023
@charjr charjr deleted the custom-query-parsing branch March 25, 2024 18:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants