Skip to content

Commit f2dd63d

Browse files
author
momijizukamori
committed
Try setting non-utf8 searches to empty?
1 parent 1ed419c commit f2dd63d

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

app/Http/Requests/Api/SearchRequest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ protected function prepareForValidation()
5959
$this->merge(['sort' => 'added_new']);
6060
}
6161
if (!mb_detect_encoding($this->search, 'utf-8', true)) {
62-
$this->merge(['search' => null]);
62+
$this->merge(['search' => '']);
6363
}
6464
}
6565

app/Http/Requests/SearchRequest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ protected function prepareForValidation()
5050
$this->merge(['sort' => 'added_new']);
5151
}
5252
if (!mb_detect_encoding($this->search, 'utf-8', true)) {
53-
$this->merge(['search' => null]);
53+
$this->merge(['search' => '']);
5454
}
5555
}
5656

0 commit comments

Comments
 (0)