Fix issue where an array is passed instead of a string.

This commit is contained in:
James Cole 2018-09-28 07:46:23 +02:00
parent ab5b7f7893
commit 791b028dc4
No known key found for this signature in database
GPG Key ID: C16961E655E74B5E

View File

@ -416,7 +416,9 @@ class AutoCompleteController extends Controller
$return = array_values(
array_unique(
array_filter(
$return, function (string $value) use ($search) {
$return, function (array $array) use ($search) {
$value = $array['name'];
return !(false === stripos($value, $search));
}, ARRAY_FILTER_USE_BOTH
)