Fixed redirecting for reset password and flashes