Larastan: Query\Builder::dynamicWhere() expects array, string given

Created on 18 Oct 2019  路  4Comments  路  Source: nunomaduro/larastan

  • Larastan Version: 0.4.2
  • --level used: 5
  • Laravel version 6.3

Description

Similar to https://github.com/nunomaduro/larastan/issues/272 I am getting false positives.

Laravel code where the issue was found

Commission::query()
    ->whereNotNull('reviewed_at')
    ->whereHas('user')
    ->get();

Curiously enough, if I leave out either of the where() calls, the error is gone.

Most helpful comment

That code doesn't even use dynamic wheres. It's just builder methods. I. Guess this will also be fixed with #325

All 4 comments

That code doesn't even use dynamic wheres. It's just builder methods. I. Guess this will also be fixed with #325

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

Yep, seems to have been fixed. Thanks!

Good job @canvural

Was this page helpful?
0 / 5 - 0 ratings