The devise was completely returning a flash alert when "Recaptcha" caught wrong keywords.
But after I updated devise version from 1.4.7 to 2.1.0, it always says, "undefined method `render_with_scope' for #"
Does anyone have the same problem? Is this all because of compatibility of devise 2.1.0 with "Recaptcha"?
I got the same error
In my registration_controller.rb i change render_with_scope :new to render :new that worked for my application.
class RegistrationsController < Devise::RegistrationsController
## This controller overwrite the create method of the users Registration controller
def create
if verify_recaptcha
super
else
build_resource
clean_up_passwords(resource)
flash.now[:alert] = "There was an error with the recaptcha code below. Please re-enter the code."
#render_with_scope :new #dld one
render :new
end
end
end
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With