Skip to content

Commit 598800b

Browse files
committed
renamed variables
1 parent bf64322 commit 598800b

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

server/src/main/java/org/elasticsearch/search/fetch/subphase/highlight/HighlightPhase.java

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -175,16 +175,16 @@ private Query getHighlighterQuery(FetchContext context, SearchHighlightContext.F
175175
}
176176

177177
private Query getHighlighterQueryForConstantFieldType(FetchContext context, MappedFieldType fieldType) {
178-
if (context.query() instanceof MatchAllDocumentQueryWrapper persist) {
179-
return new TermQuery(new Term(fieldType.name(), persist.getPattern()));
180-
} else if (context.query() instanceof DisjunctionMaxQuery changeName) {
181-
for (Query query : changeName.getDisjuncts()) {
182-
if (query instanceof MatchAllDocumentQueryWrapper anyPersist) {
183-
if (Regex.simpleMatch(anyPersist.getPattern(), getValueForConstantFieldType(context, fieldType))) {
178+
if (context.query() instanceof MatchAllDocumentQueryWrapper matchAllDocumentQueryWrapper) {
179+
return new TermQuery(new Term(fieldType.name(), matchAllDocumentQueryWrapper.getPattern()));
180+
} else if (context.query() instanceof DisjunctionMaxQuery unionOfQueries) {
181+
for (Query query : unionOfQueries.getDisjuncts()) {
182+
if (query instanceof MatchAllDocumentQueryWrapper matchAllDocumentQueryWrapper) {
183+
if (Regex.simpleMatch(matchAllDocumentQueryWrapper.getPattern(), getValueForConstantFieldType(context, fieldType))) {
184184
return new TermQuery(new Term(fieldType.name(), getValueForConstantFieldType(context, fieldType)));
185185
}
186186
}
187-
}
187+
}git
188188
}
189189
return new MatchNoDocsQuery();
190190
}

0 commit comments

Comments
 (0)