On Mar 25, 11:36 pm, Bharat Ruparel <[email protected]>
wrote:
> Figured it out:
>
> Rails 2.3 has a problem with requiring any files within the initializer
> block as shown below.
>
> Rails::Initializer.run do |config|
>
>   require "#{RAILS_ROOT}/lib/active_record_extensions.rb"
>
> end

ActiveRecord is not loaded at this point. The right place for this
sort of stuff is in an initializer (see
http://www.spacevatican.org/2008/11/21/environment-rb-and-requiring-dependencies
for ways where putting it at the bottom of environment.rb can go
wrong).

Fred

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to