Skip to content

Commit

Permalink
Fix admin grid filter backslash escaping issue
Browse files Browse the repository at this point in the history
  • Loading branch information
wubinworks committed Jan 11, 2025
1 parent 6cfb9b6 commit d1276bb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/code/Magento/Ui/Component/Filters/Type/Input.php
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ protected function applyFilter(): void
$valueExpression = $filterConfig['valueExpression'] ?? null;
}
if ($conditionType === self::CONDITION_LIKE) {
$value = str_replace(['%', '_'], ['\%', '\_'], $value);
$value = str_replace(['\\', '%', '_'], ['\\\\', '\%', '\_'], $value);
$valueExpression = $valueExpression ?? '%%%s%%';
}
if ($valueExpression) {
Expand Down

0 comments on commit d1276bb

Please sign in to comment.