We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ba2baa8 commit 47ad85fCopy full SHA for 47ad85f
1 file changed
app/controllers/users/passwords_controller.rb
@@ -18,6 +18,20 @@ def create
18
notice: "If the account exists you will receive an email or SMS with instructions on how to reset your password in a few minutes."
19
end
20
21
+
22
+ def update
23
+ self.resource = resource_class.reset_password_by_token(resource_params)
24
25
+ yield resource if block_given?
26
27
+ if resource.errors.empty?
28
+ flash[:notice] = "Your password has been changed successfully."
29
+ redirect_to new_session_path(resource_name)
30
+ else
31
+ respond_with resource
32
+ end
33
34
35
private
36
37
def render_error
0 commit comments