From d3ba8bd48741d58b2d1192aa9701ea3147215e37 Mon Sep 17 00:00:00 2001 From: kimchy Date: Sat, 19 Feb 2011 01:41:48 +0200 Subject: [PATCH] use parsing field to check for order --- .../elasticsearch/search/facet/terms/TermsFacetProcessor.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/elasticsearch/src/main/java/org/elasticsearch/search/facet/terms/TermsFacetProcessor.java b/modules/elasticsearch/src/main/java/org/elasticsearch/search/facet/terms/TermsFacetProcessor.java index 3bbfac5f28b..26722cf2bfc 100644 --- a/modules/elasticsearch/src/main/java/org/elasticsearch/search/facet/terms/TermsFacetProcessor.java +++ b/modules/elasticsearch/src/main/java/org/elasticsearch/search/facet/terms/TermsFacetProcessor.java @@ -114,7 +114,7 @@ public class TermsFacetProcessor extends AbstractComponent implements FacetProce regex = parser.text(); } else if ("regex_flags".equals(currentFieldName) || "regexFlags".equals(currentFieldName)) { regexFlags = parser.text(); - } else if ("order".equals(currentFieldName) || "comparator".equals(field)) { + } else if ("order".equals(currentFieldName) || "comparator".equals(currentFieldName)) { comparatorType = TermsFacet.ComparatorType.fromString(parser.text()); } else if ("script".equals(currentFieldName)) { script = parser.text();