I have added a method to the ActiveRecords module and put it in the lib
directory like so:
module ActiveRecord
class Base
def self.my_search(search, current_page, search_field, user_role,
perms)
...
end
end
end
This method has worked flawlessly in Rails 2.3.x and still works fine.
But Rails 3 refuses to find it. This is in-spite of executing the
following statement in config/application.rb file of Rails 3:
# Custom directories with classes and modules you want to be
autoloadable.
config.autoload_paths += %W(#{Rails.root}/lib)
What am I doing wrong?
Thanks.
Bharat
--
Posted via http://www.ruby-forum.com/.
--
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
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en.