Skip to content

Commit

Permalink
Update version check
Browse files Browse the repository at this point in the history
Signed-off-by: Harsha Vamsi Kalluri <[email protected]>
  • Loading branch information
harshavamsi committed Aug 22, 2024
1 parent 4b012e9 commit 20de476
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ public TermsQueryBuilder(StreamInput in) throws IOException {
termsLookup = in.readOptionalWriteable(TermsLookup::new);
values = (List<?>) in.readGenericValue();
this.supplier = null;
if (in.getVersion().after(Version.V_3_0_0)) {
if (in.getVersion().onOrAfter(Version.V_3_0_0)) {
rewriteOverride = in.readOptionalString();
}
if (in.getVersion().onOrAfter(Version.V_2_17_0)) {
Expand All @@ -274,7 +274,7 @@ protected void doWriteTo(StreamOutput out) throws IOException {
out.writeString(fieldName);
out.writeOptionalWriteable(termsLookup);
out.writeGenericValue(values);
if (out.getVersion().after(Version.V_3_0_0)) {
if (out.getVersion().onOrAfter(Version.V_3_0_0)) {
out.writeOptionalString(rewriteOverride);
}
if (out.getVersion().onOrAfter(Version.V_2_17_0)) {
Expand Down

0 comments on commit 20de476

Please sign in to comment.