diff options
author | Go MAEDA <maeda@farend.jp> | 2021-12-13 09:16:46 +0000 |
---|---|---|
committer | Go MAEDA <maeda@farend.jp> | 2021-12-13 09:16:46 +0000 |
commit | 3cb5f9d6c5404603399f6472aed4266377651b8c (patch) | |
tree | 63e631a3053081166c668c8a89aef0c2c8b41514 /app/models/auth_source_ldap.rb | |
parent | b4dbd821c903f3b30bd2b188562462ee21383e9b (diff) | |
download | redmine-3cb5f9d6c5404603399f6472aed4266377651b8c.tar.gz redmine-3cb5f9d6c5404603399f6472aed4266377651b8c.zip |
Include an authentication method name in LDAP connection error messages (#33345).
Contributed by Yuichi HARADA.
git-svn-id: http://svn.redmine.org/redmine/trunk@21310 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/models/auth_source_ldap.rb')
-rw-r--r-- | app/models/auth_source_ldap.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/app/models/auth_source_ldap.rb b/app/models/auth_source_ldap.rb index 8ed7ce27f..888493338 100644 --- a/app/models/auth_source_ldap.rb +++ b/app/models/auth_source_ldap.rb @@ -63,7 +63,7 @@ class AuthSourceLdap < AuthSource end end rescue *NETWORK_EXCEPTIONS => e - raise AuthSourceException.new(e.message) + raise AuthSourceException.new("#{auth_method_name}: #{e.message}") end # Test the connection to the LDAP @@ -77,7 +77,7 @@ class AuthSourceLdap < AuthSource end end rescue *NETWORK_EXCEPTIONS => e - raise AuthSourceException.new(e.message) + raise AuthSourceException.new("#{auth_method_name}: #{e.message}") end def auth_method_name @@ -107,7 +107,7 @@ class AuthSourceLdap < AuthSource end results rescue *NETWORK_EXCEPTIONS => e - raise AuthSourceException.new(e.message) + raise AuthSourceException.new("#{auth_method_name}: #{e.message}") end def ldap_mode @@ -144,7 +144,7 @@ class AuthSourceLdap < AuthSource return yield end rescue Timeout::Error => e - raise AuthSourceTimeoutException.new(e.message) + raise AuthSourceTimeoutException.new("#{auth_method_name}: #{e.message}") end def ldap_filter |