File tree Expand file tree Collapse file tree 1 file changed +0
-22
lines changed
src/Pecee/BooleanQueryParser Expand file tree Collapse file tree 1 file changed +0
-22
lines changed Original file line number Diff line number Diff line change @@ -45,9 +45,6 @@ public function parse(string $string): ?string
45
45
return null ;
46
46
}
47
47
48
- // Clean the words of anything we dont want
49
- $ tokens = $ this ->secondClean ($ tokens );
50
-
51
48
// Any hyphenated words should be merged to they are taken as is (john-paul should be "john-paul" not +john -paul)
52
49
$ tokens = $ this ->mergeHyphenatedWords ($ tokens );
53
50
@@ -106,25 +103,6 @@ protected function firstClean(string $string): string
106
103
return strtolower (trim ($ output ));
107
104
}
108
105
109
- /**
110
- * We need to process each element in turn now and clean/sanitise it
111
- *
112
- * @param array $tokens
113
- *
114
- * @return array
115
- */
116
- protected function secondClean (array $ tokens ): array
117
- {
118
- $ toReturn = [];
119
-
120
- foreach ($ tokens as $ token ) {
121
- $ token = preg_replace ('/[^\p{L}0-9 @\(\)\-\+\*\"\.]/ui ' , '' , $ token );
122
- $ toReturn [] = $ token ;
123
- }
124
-
125
- return $ toReturn ;
126
- }
127
-
128
106
/**
129
107
* Because we don't want hyphenated words to be treated differently, lets merge them in quotes
130
108
*
You can’t perform that action at this time.
0 commit comments