I am trying to override the create method from the registration controller in Devise to enable Recaptcha validation (as seen here and here ):
class RegistrationsController < Devise::RegistrationsController def create if verify_recaptcha super else build_resource clean_up_passwords(resource) flash[:alert] = "Bad words." render_with_scope :new end end end
Also changed my .rb routes accordingly:
map.devise_for :users, :controllers => {:registrations => "registrations"}, :path_names => { :sign_up => 'signup', :sign_in => 'login', :sign_out => 'logout' }
When trying to visit a new registration page (with a new path name: http: // localhost: 3000 / users / signup ), the following errors appear:
LoadError in RegistrationsController#new Expected /home/benoror/project/app/controllers/registrations_controller.rb to define RegistrationsController
FULL ERROR TRACE
Any help was appreciated.
BTW , I am using Devise 1.0.11 and Rails 2.3.10, thanks!
source share