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

ClosureExpressionVisitor not using public method matching field name #134

Open
rikbruil opened this issue Nov 21, 2017 · 1 comment
Open

Comments

@rikbruil
Copy link

I've run into a situation where I'm using ArrayCollection to filter some objects using Criteria::orderBy().

Assume these objects have a private property 'foo', and a public method 'foo()' which returns the private property value. The ClosureExpressionVisitor will check for various public methods existence (for example is*/get* variants, or access through magic methods like __get/__call).

I have the feeling there is one more check missing here, which is checking if a public method exists that matches the field name literally (without prepending get/is or through magic methods).

I'm not sure if this was omitted with a reason, maybe this means we are using a convention thats not very widespread? I will create a PR to hopefully communicate my issue better.

@malarzm
Copy link
Member

malarzm commented Jul 13, 2021

Relates to #149

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

No branches or pull requests

2 participants