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
Ruby agile-developmentangularbcfboardsbug-trackerganttgantt-chartifcissue-trackerjira-alternativekanbanopenprojectproduct-managementproject-managementproject-planningroadmaprubyscrumtimelineworkflows
Remove unnecessary path loading config. Fix module naming for Constraints::Enterprise.
Dombi Attila8555eb6ce200
diff --git a/config/application.rb b/config/application.rbindex 1d4a8d9ceb7..3c92d6857a3 100644--- a/config/application.rb+++ b/config/application.rb@@ -113,10 +113,6 @@ module OpenProject# http://stackoverflow.com/questions/4590229config.middleware.use Rack::TempfileReaper- # Custom directories with classes and modules you want to be autoloadable.- config.paths.add Rails.root.join('lib').to_s, eager_load: true- config.paths.add Rails.root.join('lib/constraints').to_s, eager_load: true-# Add lookbook preview paths when enabledif OpenProject::Configuration.lookbook_enabled?config.paths.add Primer::ViewComponents::Engine.root.join('app/components').to_s, eager_load: truediff --git a/config/routes.rb b/config/routes.rbindex 1b94aa3b4f0..11de0c2a584 100644--- a/config/routes.rb+++ b/config/routes.rb@@ -354,7 +354,7 @@ Rails.application.routes.draw doscope 'admin' doresource :announcements, only: %i[edit update]- constraints(Enterprise) do+ constraints(Constraints::Enterprise) doresource :enterprise, only: %i[show create destroy]scope controller: 'enterprises' dopost 'enterprise/save_trial_key' => 'enterprises#save_trial_key'diff --git a/lib/constraints/enterprise.rb b/lib/constraints/enterprise.rbindex ff7a856fe0c..181869481a2 100644--- a/lib/constraints/enterprise.rb+++ b/lib/constraints/enterprise.rb@@ -26,10 +26,12 @@# See COPYRIGHT and LICENSE files for more details.#++-module Enterprise- module_function+module Constraints+ module Enterprise+ module_function- def matches?(_request)- OpenProject::Configuration.ee_manager_visible?+ def matches?(_request)+ OpenProject::Configuration.ee_manager_visible?+ endendend