diff --git a/modules/elasticsearch/src/main/java/org/elasticsearch/index/mapper/xcontent/RoutingFieldMapper.java b/modules/elasticsearch/src/main/java/org/elasticsearch/index/mapper/xcontent/RoutingFieldMapper.java index 06b326445de..29285df322a 100644 --- a/modules/elasticsearch/src/main/java/org/elasticsearch/index/mapper/xcontent/RoutingFieldMapper.java +++ b/modules/elasticsearch/src/main/java/org/elasticsearch/index/mapper/xcontent/RoutingFieldMapper.java @@ -89,7 +89,7 @@ public class RoutingFieldMapper extends AbstractFieldMapper implements o } public void markAsRequired() { - this.required = required; + this.required = true; } @Override public boolean required() {