Skip to content

Commit

Permalink
[BUGFIX] Hardening against invalid UTF-8 Chars
Browse files Browse the repository at this point in the history
  • Loading branch information
kaystrobach authored Jan 26, 2022
1 parent 32be065 commit 5952fab
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Classes/ViewHelpers/Widget/Controller/SearchController.php
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ public function valuesAction($facet = '', $query = [], $term = '')
$term
);

return json_encode($values);
return json_encode($values, JSON_THROW_ON_ERROR|JSON_INVALID_UTF8_IGNORE);
}

/**
Expand All @@ -112,7 +112,7 @@ public function facetsAction($query = [], $term = '')
$term
);

return json_encode($facets);
return json_encode($facets, JSON_THROW_ON_ERROR|JSON_INVALID_UTF8_IGNORE);
}

/**
Expand Down

0 comments on commit 5952fab

Please sign in to comment.