When attempting to implement $geoIntersect
in Meteor, I encountered an error:
MongoError: Malformed geo query: { $geoIntersects: { $geometry: { type: "Point", coordinates: [ { lng: "34.8933452", lat: "31.9444389" } ] } } }
Could someone confirm if $geoIntersect
is supported by the Meteor 1.0 MongoDB driver?
This is the code snippet I am using within Meteor.publish
:
Collection.find({
polygons: {
$geoIntersects: {
$geometry: {
type: "Point",
coordinates: location
}
}
}
}).fetch();