[Rails 3.2] class in lib does not override class in engine

Erwin
2013-04-18T12:17:45Z

I am mounting the engine  ''opro_oauth''  gem in my routes

mount_opro_oauth


I want to overwrite a method from the engine lib:
/lib/opro/auth_provider/devise.rb

module Opro
>   module AuthProvider
>     class Devise
> ...
>       def find_user_for_auth(params)
>       ...
>       end
>     end
>   end
> end


So, I added the modified devise.rb n my iapp ,
/lib/opro/auth_provider/devise.rb
and added     config.autoload_paths +=
["#{config.root}/lib/opro/auth_provider"]   in my application.rb
I inserted a debigger statement to check if the method is reached but no
way, the original method is always run..  what''s wrong with my setup...
??

thanks for feedback


--
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to
rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit
https://groups.google.com/d/msg/rubyonrails-talk/-/QB1FwQtAUx0J.
For more options, visit https://groups.google.com/groups/opt_out.