diff --git a/modules/elasticsearch/src/main/java/org/elasticsearch/index/field/data/bytes/ByteFieldDataComparator.java b/modules/elasticsearch/src/main/java/org/elasticsearch/index/field/data/bytes/ByteFieldDataComparator.java index 51e7d60e585..1123dd9a182 100644 --- a/modules/elasticsearch/src/main/java/org/elasticsearch/index/field/data/bytes/ByteFieldDataComparator.java +++ b/modules/elasticsearch/src/main/java/org/elasticsearch/index/field/data/bytes/ByteFieldDataComparator.java @@ -46,7 +46,7 @@ public class ByteFieldDataComparator extends NumericFieldDataComparator { } @Override public int compareBottom(int doc) { - return bottom - currentFieldData.shortValue(doc); + return bottom - currentFieldData.byteValue(doc); } @Override public void copy(int slot, int doc) {