diff --git a/CHANGELOG.md b/CHANGELOG.md index 67e81f4..e99bbac 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,14 @@ This changelog references the relevant changes (bug and security fixes) done to `orchestra/support`. +## 3.6.2 + +Released: 2018-07-10 + +### Fixes + +* Fixes `Orchestra\Support\Concerns\QueryFilter::buildWildcardForField()` to accept `Illuminate\Database\Query\Expression` as `$field` variable instead of casting it to `string`. + ## 3.6.1 Released: 2018-07-07 diff --git a/src/Support/Concerns/QueryFilter.php b/src/Support/Concerns/QueryFilter.php index a28607a..16fbc73 100644 --- a/src/Support/Concerns/QueryFilter.php +++ b/src/Support/Concerns/QueryFilter.php @@ -129,12 +129,12 @@ protected function buildWildcardQueryFilters($query, array $fields, array $keywo * Build wildcard query filter for field using where or orWhere. * * @param \Illuminate\Database\Eloquent\Builder|\Illuminate\Database\Query\Builder $query - * @param string $field + * @param \Illuminate\Database\Query\Expression|string $field * @param array $keyword * * @return \Illuminate\Database\Eloquent\Builder|\Illuminate\Database\Query\Builder */ - protected function buildWildcardForField($query, string $field, array $keyword) + protected function buildWildcardForField($query, $field, array $keyword) { if ($field instanceof Expression) { return $this->buildWildcardForFieldUsing($query, $field->getValue(), $keyword, 'orWhere');