Skip to content

Commit

Permalink
fix where clause for route key.
Browse files Browse the repository at this point in the history
  • Loading branch information
ahmedbally committed Sep 10, 2023
1 parent 88799c4 commit b209359
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Traits/OptimusEncodedRouteKey.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ public function resolveRouteBindingQuery($query, $value, $field = null)
$value = $this->getOptimus()->decode($value);
}

return $query->where($field ?? $this->getRouteKeyName(), $value);
return $query->where($field, $value);
}

/**
Expand Down

0 comments on commit b209359

Please sign in to comment.