diff --git a/flask_security/exceptions.py b/flask_security/exceptions.py deleted file mode 100644 index 47be66b..0000000 --- a/flask_security/exceptions.py +++ /dev/null @@ -1,52 +0,0 @@ -# -*- coding: utf-8 -*- -""" - flask.ext.security.exceptions - ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - - Flask-Security exceptions module - - :copyright: (c) 2012 by Matt Wright. - :license: MIT, see LICENSE for more details. -""" - - -class SecurityError(Exception): - def __init__(self, message=None, user=None): - super(SecurityError, self).__init__(message) - self.user = user - - -class BadCredentialsError(SecurityError): - """Raised when an authentication attempt fails due to an error with the - provided credentials. - """ - - -class UserNotFoundError(SecurityError): - """Raised by a user datastore when there is an attempt to find a user by - their identifier, often username or email, and the user is not found. - """ - - -class RoleNotFoundError(SecurityError): - """Raised by a user datastore when there is an attempt to find a role and - the role cannot be found. - """ - - -class ConfirmationError(SecurityError): - """Raised when an confirmation error occurs - """ - - -class ResetPasswordError(SecurityError): - """Raised when a password reset error occurs - """ - - -class PasswordlessLoginError(SecurityError): - """Raised when a passwordless login error occurs - """ - def __init__(self, message=None, user=None, next=None): - super(PasswordlessLoginError, self).__init__(message, user) - self.next = next diff --git a/flask_security/views.py b/flask_security/views.py index 7d94735..f6834d3 100644 --- a/flask_security/views.py +++ b/flask_security/views.py @@ -257,7 +257,6 @@ def create_blueprint(state, import_name): methods=['GET', 'POST'], endpoint='login')(send_login) bp.route(state.login_url + '/', - methods=['GET'], endpoint='token_login')(token_login) else: bp.route(state.login_url,