Larastan: $queryBuilder->leftJoin()->get() returns wrong Collection

Created on 14 Jul 2019  路  4Comments  路  Source: nunomaduro/larastan

  • Larastan Version: 0.3.16
  • --level used:7

Description

When a leftJoin is used with the query builder it will be seen as returning Illuminate\Support\Collection instead of Illuminate\Database\Eloquent\Collection.
If you leave out the leftJoin it actually detects the correct type.

Laravel code where the issue was found

$user->clients()->leftJoin('keywords', 'keywords.keyword_group_id', '=', 'keyword_groups.id')->get();

Most helpful comment

OK. So I'm closing this.

All 4 comments

Can you test this with the latest changes in master branch?

Sorry I no longer have access to the affected source.

Thank you for your answer.

OK. So I'm closing this.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

jdrieghe picture jdrieghe  路  4Comments

grcasanova picture grcasanova  路  4Comments

zlodes picture zlodes  路  3Comments

Gummibeer picture Gummibeer  路  3Comments

mariomka picture mariomka  路  4Comments