Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

Allow creating users from the authSource link

Oliver Güntherde8489bc1d10
diff --git a/lib/api/v3/users/user_representer.rb b/lib/api/v3/users/user_representer.rb
index b31daa7546b..8c8f8a00650 100644
--- a/lib/api/v3/users/user_representer.rb
+++ b/lib/api/v3/users/user_representer.rb
@@ -184,7 +184,7 @@ module API
##
# Used while parsing JSON to initialize `ldap_auth_source_id` through the given link.
def initialize_embedded_links!(data)
- ldap_auth_source_id = parse_auth_source_id data, "auth_source"
+ ldap_auth_source_id = parse_auth_source_id(data, "authSource") || parse_auth_source_id(data, "auth_source")
if ldap_auth_source_id
auth_source = LdapAuthSource.find_by_unique(ldap_auth_source_id) # rubocop:disable Rails/DynamicFindBy