Mongoid fails on ruby 1.9.3
问题 So I'm playing around with mongo stuffs. Created a new heroku app, added a mongolab option to it, but every mongoid method fails. I googled around, and it looks like this issue was common with ruby prior to 1.9.3, but I'm running 1.9.3. Here's the simplest failing sample: require 'sinatra' require 'mongoid' require 'json' require "sinatra/reloader" if development? Mongoid.load!("mongoid.yml") class Company include Mongoid::Document field :code, type: String field :sector, type: String field