Skip to content

[5.8] Argument 1 passed to Illuminate\Database\Query\Builder::cleanBindings() must be of the type array, null given #28251

@Cannonb4ll

Description

@Cannonb4ll
  • Laravel Version: 5.8.12
  • PHP Version: 7.2.14
  • Database Driver & Version: MySQL 5.7.20

Description:

Just this morning upgraded from 5.8.11 to 5.8.12 which completely broke my application on the wherePivot part.

Broken:

$variable = $user->books()->wherePivot('owner', true)->findOrFail($id);

Fixed:

$variable = $user->books()->wherePivot('owner', '=', true)->findOrFail($id);

Has this been done intentionally? I cannot find anything regarding this change inside the core update. My code has not changed since the upgrade from 5.8.11 -> 5.8.12

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions