Friday, May 25, 2012

Undefined local variable or method `version_requirements' for ...

I was getting the error while installing an older rails application. After googling I've got the solution from a discussion thread to add following block in right before the initialization in to config/environment.rb and worked for me.
if Gem::VERSION >= "1.3.6"
  module Rails
    class GemDependency
      def requirement
        r = super
        (r == Gem::Requirement.default) ? nil : r
      end
    end
  end
end

No comments:

Post a Comment