ryanong / mongoid_spacial

A Mongoid Extention that simplifies and adds support for MongoDB Geo Spacial Calculations.
MIT License
138 stars 63 forks source link

Wrong collection used when store_in is specified #1

Closed ianiv closed 13 years ago

ianiv commented 13 years ago

If the collection name for a class is explicitly specified using "store_in" then the wrong collection name is used in geoNear queries. For example:

class V2::User
  include Mongoid::Document
  include Mongoid::Spacial::Document

  store_in :users

end

geoNear queries for that class will try to use the collection "v2/user" instead of "users"