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 type on SqlWalker::walkPathExpression() #9565

Merged
merged 1 commit into from
Mar 20, 2022

Conversation

derrabus
Copy link
Member

@derrabus derrabus commented Mar 6, 2022

The parameter of SqlWalker::walkPathExpression() is annotated as mixed, but passing anything but a PathExpression to it would result in an error because the method accesses properties on the passed value.

Comment on lines -33 to -36
public function dispatch($sqlWalker)
{
return $sqlWalker->walkPathExpression($this);
}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've removed this method because there's no way a call to this method could've returned anything. The parent class contains an implementation of that method that raises a proper exception, so it seems just right to fall back to that.

@derrabus derrabus added this to the 2.12.0 milestone Mar 6, 2022
@derrabus derrabus requested a review from greg0ire March 20, 2022 12:09
@derrabus derrabus merged commit 98b468d into doctrine:2.12.x Mar 20, 2022
@derrabus derrabus deleted the types/walk-path-expression branch March 20, 2022 12:42
n-e-m-a-nj-a pushed a commit to n-e-m-a-nj-a/orm that referenced this pull request Mar 29, 2022
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.

2 participants