Skip to content

Conversation

pascalbaljet
Copy link
Member

The code below causes PHPStan errors because the second argument is an Expression instance. The instance will eventually be transformed in Grammer::whereColumn(), so this should be allowed.

DB::table('users', 't1')->leftJoin('users AS t2', DB::raw('t1.uid + 1'), '=', 't2.uid');

I added the Expression class to more docblocks to solve this. This relates to #46160

@pascalbaljet pascalbaljet changed the title Allow Expression at more places in Query Builder [10.x] Allow Expression at more places in Query Builder Mar 7, 2024
@taylorotwell taylorotwell merged commit 745b205 into laravel:10.x Mar 7, 2024
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