-
Notifications
You must be signed in to change notification settings - Fork 507
Add FilterVarArrayDynamicReturnTypeExtension
#2257
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
Add FilterVarArrayDynamicReturnTypeExtension
#2257
Conversation
FilterVarArrayDynamicReturnTypeExtension
I was hoping it might be possible to reuse that thing, but didn't plan it through :) feel also free to change it if needed. Reminds me that I also still need to finish filter_input.. |
Since the processing for |
I started the filter_input support via #2010 but this is not the latest state and I wasn't happy yet with the local refactor. Will try to push it soon. |
@herndlm |
This pull request has been marked as ready for review. |
I intended to implement |
a missing interesting test case for
I handled this incorrectly in #2010 initially but added a new method in the helper now that should deal with this and maybe you can make use of it here too. |
hi @zonuexe, the filter_input stuff has been merged, maybe it is useful here in some way |
@herndlm Thanks for the reminder! |
This reverts commit 862b01f7595d23d1c92c1836a5bbe99e3588211b.
@ondrejmirtes Could you please review this PR? |
Thank you! |
Add a return type extension for
filter_var_array()
andfilter_input_array()
.This function is defined with the following signature:
This function supports three types of filters:
The array keys returned from
filter_var_array()
change depending on how the filter is passed, so the implementation is complex.$options
$array
$array
This PR was implemented thanks to @herndlm's
FilterFunctionReturnTypeHelper
#2190 and #2010.