Skip to content

Commit d6e23da

Browse files
committed
Revert "check nullValue instead of address. Since nullValue can only make address null"
This reverts commit 77c30b1.
1 parent 77c30b1 commit d6e23da

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

server/src/main/java/org/elasticsearch/index/mapper/IpFieldMapper.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -582,11 +582,11 @@ protected void parseCreateField(DocumentParserContext context) throws IOExceptio
582582
throw e;
583583
}
584584
}
585-
if (nullValue != null) {
585+
if (address != null) {
586586
indexValue(context, address);
587587
}
588588
if (offsetsFieldName != null && context.isImmediateParentAnArray() && context.canAddIgnoredField()) {
589-
if (nullValue != null) {
589+
if (address != null) {
590590
BytesRef sortableValue = new BytesRef(InetAddressPoint.encode(address));
591591
context.getOffSetContext().recordOffset(offsetsFieldName, sortableValue);
592592
} else {

0 commit comments

Comments
 (0)