git.iko.soy/typeable/bloodhound
on master help sign in
Changed AND Filter to put "_cache" in appropriate spot.

Fixes issues with ES > 1.0.1. Tested on 1.0.1 and 1.3.2

commitcaecf0fe36ee12c26067081356269f45c11fe2fc authorCurtis Carter <curtis@rubyhq.com> dateFri 15 Aug 2014, 13:27 (12 years ago) parent9c662b1
1 file changed+3−2
Database/Bloodhound/Types.hs+3−2
Database/Bloodhound/Types.hs+3−2
@@ -949,8 +949,9 @@ instance Seminearring Filter where
949949
950950instance ToJSON Filter where
951951 toJSON (AndFilter filters cache) =
952− object ["and" .= fmap toJSON filters
953− , "_cache" .= cache]
952+ object ["and" .=
953+ object [ "filters" .= fmap toJSON filters
954+ , "_cache" .= cache]]
954955
955956 toJSON (OrFilter filters cache) =
956957 object ["or" .= fmap toJSON filters