From 1e1faf38c376f8b88bde72c7aee5bd5b1c264909 Mon Sep 17 00:00:00 2001 From: Alex K Date: Thu, 5 Feb 2015 08:02:25 -0800 Subject: [PATCH] derp --- src/Database/Bloodhound/Types.hs | 8 ++++---- tests/tests.hs | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Database/Bloodhound/Types.hs b/src/Database/Bloodhound/Types.hs index 8fb4ad3..cc12125 100644 --- a/src/Database/Bloodhound/Types.hs +++ b/src/Database/Bloodhound/Types.hs @@ -1407,10 +1407,10 @@ instance ToJSON Filter where rangeObject (RangeDoubleGte t) = ["gte" .= t] rangeObject (RangeDoubleLt t) = ["lt" .= t] rangeObject (RangeDoubleGt t) = ["gt" .= t] - rangeObject (RangeDoubleGteLte l g) = ["lte" .= l, "gte" .= g] - rangeObject (RangeDoubleGtLte l g) = ["lt" .= l, "gte" .= g] - rangeObject (RangeDoubleGteLt l g) = ["lte" .= l, "gt" .= g] - rangeObject (RangeDoubleGtLt l g) = ["lt" .= l, "gt" .= g] + rangeObject (RangeDoubleGteLte l g) = ["gte" .= l, "lte" .= g] + rangeObject (RangeDoubleGtLte l g) = ["gt" .= l, "lte" .= g] + rangeObject (RangeDoubleGteLt l g) = ["gte" .= l, "lt" .= g] + rangeObject (RangeDoubleGtLt l g) = ["gt" .= l, "lt" .= g] toJSON (RegexpFilter (FieldName fieldName) (Regexp regexText) flags (CacheName cacheName) cache (CacheKey cacheKey)) = diff --git a/tests/tests.hs b/tests/tests.hs index 2596856..ec8ea4b 100644 --- a/tests/tests.hs +++ b/tests/tests.hs @@ -444,7 +444,7 @@ main = hspec $ do it "returns document for range double filter" $ do _ <- insertData let filter = RangeFilterDouble (FieldName "age") - (RangeDoubleGtLt 100000.0 1000.0) + (RangeDoubleGtLt 1000.0 100000.0) RangeExecutionIndex False let search = mkSearch Nothing (Just filter) myTweet <- searchTweet search