Skip to content

Commit 1cc6eba

Browse files
committed
PR feedback
1 parent 9591c18 commit 1cc6eba

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/expression/function/EsqlFunctionRegistry.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -441,7 +441,6 @@ private static FunctionDefinition[][] functions() {
441441
new FunctionDefinition[] {
442442
def(Kql.class, uni(Kql::new), "kql"),
443443
def(Match.class, tri(Match::new), "match"),
444-
def(MatchPhrase.class, tri(MatchPhrase::new), "match_phrase"),
445444
def(MultiMatch.class, MultiMatch::new, "multi_match"),
446445
def(QueryString.class, bi(QueryString::new), "qstr") } };
447446

@@ -460,7 +459,8 @@ private static FunctionDefinition[][] snapshotFunctions() {
460459
def(AvgOverTime.class, uni(AvgOverTime::new), "avg_over_time"),
461460
def(LastOverTime.class, LastOverTime::withUnresolvedTimestamp, "last_over_time"),
462461
def(FirstOverTime.class, FirstOverTime::withUnresolvedTimestamp, "first_over_time"),
463-
def(Term.class, bi(Term::new), "term") } };
462+
def(Term.class, bi(Term::new), "term"),
463+
def(MatchPhrase.class, tri(MatchPhrase::new), "match_phrase") } };
464464
}
465465

466466
public EsqlFunctionRegistry snapshotRegistry() {

x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/expression/function/fulltext/MatchPhrase.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -186,8 +186,7 @@ private static MatchPhrase readFrom(StreamInput in) throws IOException {
186186
Source source = Source.readFrom((PlanStreamInput) in);
187187
Expression field = in.readNamedWriteable(Expression.class);
188188
Expression query = in.readNamedWriteable(Expression.class);
189-
QueryBuilder queryBuilder = null;
190-
queryBuilder = in.readOptionalNamedWriteable(QueryBuilder.class);
189+
QueryBuilder queryBuilder = in.readOptionalNamedWriteable(QueryBuilder.class);
191190
return new MatchPhrase(source, field, query, null, queryBuilder);
192191
}
193192

0 commit comments

Comments
 (0)