Skip to content

Commit 7539e8e

Browse files
committed
fix-issue-20689
1 parent cb681ab commit 7539e8e

File tree

3 files changed

+1
-4
lines changed

3 files changed

+1
-4
lines changed

app/code/Magento/Search/Model/ResourceModel/SynonymReader.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,6 @@ protected function _construct()
8585
*/
8686
private function queryByPhrase($phrase)
8787
{
88-
$phrase = rtrim($phrase, "-");
8988
$matchQuery = $this->fullTextSelect->getMatchQuery(
9089
['synonyms' => 'synonyms'],
9190
$phrase,

app/code/Magento/Search/Model/SynonymAnalyzer.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,6 @@ public function getSynonymsForPhrase($phrase)
5454
return $result;
5555
}
5656

57-
$phrase = rtrim($phrase, "-");
58-
5957
$synonymGroups = $this->getSynonymGroupsByPhrase($phrase);
6058

6159
// Replace multiple spaces in a row with the only one space

lib/internal/Magento/Framework/Search/Adapter/Mysql/Query/Builder/Match.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ class Match implements QueryInterface
2626
/**
2727
* @var string
2828
*/
29-
const SPECIAL_CHARACTERS = '+~/\\<>\'":*$#@()!,.?`=%&^';
29+
const SPECIAL_CHARACTERS = '-+~/\\<>\'":*$#@()!,.?`=%&^';
3030

3131
const MINIMAL_CHARACTER_LENGTH = 3;
3232

0 commit comments

Comments
 (0)