mirror of
https://github.com/jumpserver/jumpserver.git
synced 2025-12-22 20:12:56 +00:00
perf: Remove unused CAS user exception handling and simplify login view error response (#16380)
* perf: Remove unused CAS user exception handling and simplify login view error response * perf: position code --------- Co-authored-by: wangruidong <940853815@qq.com> Co-authored-by: Bai <baijiangjie@gmail.com>
This commit is contained in:
@@ -46,6 +46,10 @@ def _save_original_get_or_create():
|
||||
_django_original_get_or_create = _save_original_get_or_create()
|
||||
|
||||
|
||||
class OnlyAllowExistUserAuthError(Exception):
|
||||
pass
|
||||
|
||||
|
||||
def _authenticate_context(func):
|
||||
"""
|
||||
装饰器:管理 authenticate 函数的执行上下文
|
||||
@@ -127,10 +131,6 @@ def _get_backends(return_tuples=False):
|
||||
return backends
|
||||
|
||||
|
||||
class OnlyAllowExistUserAuthError(Exception):
|
||||
pass
|
||||
|
||||
|
||||
auth._get_backends = _get_backends
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user