Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Redirect after pass reset

  • Loading branch information...
commit 2bd95a1eb4e5570eb0d8a27b5525d750ecdd8e24 1 parent c7cd308
Zbigniew Lukasiak authored

Showing 1 changed file with 8 additions and 1 deletion. Show diff stats Hide diff stats

  1. +8 1 lib/WebPrototypes/ResetPass.pm
9 lib/WebPrototypes/ResetPass.pm
@@ -34,6 +34,9 @@ sub call {
34 34 if( $path eq '/reset' ){
35 35 return $self->_reset( $env );
36 36 }
  37 + if( $path eq '/after' ){
  38 + return $self->build_reply( "Password reset - you can now login with the new one" );
  39 + }
37 40 return $self->_index( $env );
38 41 }
39 42
@@ -105,7 +108,11 @@ sub _reset {
105 108 else{
106 109 if( $req->method eq 'POST' ){
107 110 $self->update_user( $user, { pass_token => undef, password => $req->param( 'password' ) } );
108   - return $self->build_reply( 'Password reset' );
  111 + return [
  112 + 301,
  113 + [ Location => 'after'],
  114 + [ $self->wrap_text( "Password reset" ) ]
  115 + ];
109 116 }
110 117 else{
111 118 my $encoded_name = url_encode_utf8( $name );

0 comments on commit 2bd95a1

Please sign in to comment.
Something went wrong with that request. Please try again.