Fix for issue #456 - Fixes unwanted breaking change for array input names#461
Merged
gertdreyer merged 1 commit intofinal-form:mainfrom Jan 11, 2023
Conversation
…ay input names introduced in v4.20.3 (a3575ef) - v4.20.2 used to work fine
Member
|
Published in |
Contributor
Author
|
@erikras Thank you! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fix for issue #456 - Fixes unwanted breaking change for array input names introduced in v4.20.3 (a3575ef) - v4.20.2 used to work fine
Hello @erikras and @jedwards1211,
Commit a3575ef (PR 381) introduced a breaking change for array input names like
choices[]andoptions[](see issue #456).In v4.20.2, keys like
"choices[]"and"options[]"all map to the following correct paths:["choices"],["options"].Since v4.20.3, after PR 381 was merged,
"choices[]"and"options[]"started to map to
["choices", ""]and["options", ""], which is not retro-compatible with what we had in v4.20.2 and breaks some of our forms relying on array input names likechoices[].A few months ago I created an issue about this unwanted breaking change here: #456
This PR fixes issue #456 and restores the previous behaviour for keys like
choices[],options[], etc...@erikras Could you please review it and release a new patch version with this patch?
We currently cannot upgrade
final-formto v4.20.3 and above because of this issue.Thanks!