lib/mongo_mapper.rb in mongo_mapper-0.6.7 vs lib/mongo_mapper.rb in mongo_mapper-0.6.8
- old
+ new
@@ -1,4 +1,14 @@
+# if Gem is defined i'll assume you are using rubygems and lock specific versions
+# call me crazy but a plain old require will just get the latest version you have installed
+# so i want to make sure that if you are using gems you do in fact have the correct versions
+# if there is a better way to do this, please enlighten me!
+if self.class.const_defined?(:Gem)
+ gem 'activesupport', '>= 2.3'
+ gem 'mongo', '0.18.1'
+ gem 'jnunemaker-validatable', '1.8.1'
+end
+
require 'active_support'
require 'mongo'
require 'validatable'
module MongoMapper