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

Use present? on filter string

Oliver Günthercbc65b8b221d
diff --git a/app/models/ldap_auth_source.rb b/app/models/ldap_auth_source.rb
index a8fa4e2e500..ea4a9fc78fb 100644
--- a/app/models/ldap_auth_source.rb
+++ b/app/models/ldap_auth_source.rb
@@ -185,7 +185,7 @@ class LdapAuthSource < AuthSource
end
def parsed_filter_string
- Net::LDAP::Filter.from_rfc2254(filter_string) if filter_string
+ Net::LDAP::Filter.from_rfc2254(filter_string) if filter_string.present?
end
private