Skip to content

Commit 4c76525

Browse files
committed
Use encoded value when recording array offsets
1 parent bcb195e commit 4c76525

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1117,7 +1117,7 @@ protected void parseCreateField(DocumentParserContext context) throws IOExceptio
11171117
boolean indexed = indexValue(context, value);
11181118
if (offsetsFieldName != null && context.isImmediateParentAnArray() && context.canAddIgnoredField()) {
11191119
if (indexed) {
1120-
context.getOffSetContext().recordOffset(offsetsFieldName, value.string());
1120+
context.getOffSetContext().recordOffset(offsetsFieldName, value.bytes());
11211121
} else if (value == null) {
11221122
context.getOffSetContext().recordNull(offsetsFieldName);
11231123
}

0 commit comments

Comments
 (0)