1
0
mirror of https://github.com/meineerde/redmine.git synced 2026-01-01 05:09:40 +00:00

LDAP account creation fails when first name/last name contain non ASCII (#21453).

Patch by Haihan Ji.

git-svn-id: http://svn.redmine.org/redmine/trunk@15024 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang 2016-01-09 10:17:12 +00:00
parent 5e5506587e
commit 624cdea92a

View File

@ -197,7 +197,8 @@ class AuthSourceLdap < AuthSource
def self.get_attr(entry, attr_name)
if !attr_name.blank?
entry[attr_name].is_a?(Array) ? entry[attr_name].first : entry[attr_name]
value = entry[attr_name].is_a?(Array) ? entry[attr_name].first : entry[attr_name]
value.force_encoding('UTF-8')
end
end
end