Skip to content

Commit a2928a5

Browse files
author
Markus Machatschek
committed
chore: remove version check in the like implementations as well
1 parent ff9b257 commit a2928a5

File tree

2 files changed

+0
-14
lines changed

2 files changed

+0
-14
lines changed

src/Query/BuilderWhere.php

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
namespace Tpetry\PostgresqlEnhanced\Query;
66

77
use Illuminate\Database\Query\Expression;
8-
use Illuminate\Support\Facades\App;
98

109
trait BuilderWhere
1110
{
@@ -68,10 +67,6 @@ public function orWhereIntegerArrayMatches($column, string $query): static
6867
*/
6968
public function orWhereLike($column, $value, $caseSensitive = false): static
7069
{
71-
if (version_compare(App::version(), '11.17.0', '>=')) {
72-
return parent::orWhereLike($column, $value, $caseSensitive);
73-
}
74-
7570
return $this->whereLike($column, $value, $caseSensitive, 'or', false);
7671
}
7772

@@ -193,10 +188,6 @@ public function whereIntegerArrayMatches($column, string $query): static
193188
*/
194189
public function whereLike($column, $value, $caseSensitive = false, $boolean = 'and', $not = false): static
195190
{
196-
if (version_compare(App::version(), '11.17.0', '>=')) {
197-
return parent::whereLike($column, $value, $caseSensitive, $boolean, $not);
198-
}
199-
200191
$type = 'like';
201192

202193
$this->wheres[] = compact('type', 'column', 'value', 'caseSensitive', 'boolean', 'not');

src/Query/GrammarWhere.php

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66

77
use Exception;
88
use Illuminate\Database\Query\Builder;
9-
use Illuminate\Support\Facades\App;
109

1110
trait GrammarWhere
1211
{
@@ -51,10 +50,6 @@ public function whereAny(Builder $query, $where): string
5150
*/
5251
public function whereLike(Builder $query, $where): string
5352
{
54-
if (version_compare(App::version(), '11.17.0', '>=')) {
55-
return parent::whereLike($query, $where);
56-
}
57-
5853
$operator = $where['not'] ? 'not ' : '';
5954
$operator .= $where['caseSensitive'] ? 'like' : 'ilike';
6055

0 commit comments

Comments
 (0)