Show More
@@ -38,9 +38,9 b' from sqlalchemy.sql.expression import tr' | |||
|
38 | 38 | from sqlalchemy.util import OrderedSet |
|
39 | 39 | from webhelpers.pylonslib.secure_form import authentication_token |
|
40 | 40 | |
|
41 | from rhodecode.authentication import legacy_plugin_prefix | |
|
41 | 42 | from rhodecode.config.routing import ADMIN_PREFIX |
|
42 | 43 | from rhodecode.lib.auth import HasRepoGroupPermissionAny, HasPermissionAny |
|
43 | from rhodecode.lib.exceptions import LdapImportError | |
|
44 | 44 | from rhodecode.lib.utils import repo_name_slug, make_db_config |
|
45 | 45 | from rhodecode.lib.utils2 import safe_int, str2bool, aslist, md5 |
|
46 | 46 | from rhodecode.lib.vcs.backends.git.repository import GitRepository |
@@ -995,12 +995,11 b' def ValidAuthPlugins():' | |||
|
995 | 995 | from rhodecode.authentication.base import loadplugin |
|
996 | 996 | module_list = value |
|
997 | 997 | unique_names = {} |
|
998 | try: | |
|
998 | 999 | for module in module_list: |
|
1000 | if module.startswith(legacy_plugin_prefix): | |
|
1001 | continue | |
|
999 | 1002 | plugin = loadplugin(module) |
|
1000 | if plugin is None: | |
|
1001 | raise formencode.Invalid( | |
|
1002 | _("Can't find plugin with id '{}'".format(module)), | |
|
1003 | value, state) | |
|
1004 | 1003 | plugin_name = plugin.name |
|
1005 | 1004 | if plugin_name in unique_names: |
|
1006 | 1005 | msg = M(self, 'import_duplicate', state, |
@@ -1008,6 +1007,8 b' def ValidAuthPlugins():' | |||
|
1008 | 1007 | next_to_load=plugin_name) |
|
1009 | 1008 | raise formencode.Invalid(msg, value, state) |
|
1010 | 1009 | unique_names[plugin_name] = plugin |
|
1010 | except (KeyError, AttributeError, TypeError) as e: | |
|
1011 | raise formencode.Invalid(str(e), value, state) | |
|
1011 | 1012 | |
|
1012 | 1013 | return _validator |
|
1013 | 1014 |
General Comments 0
You need to be logged in to leave comments.
Login now