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

avoid constant redefinition

ulfertsaacadcb29532
diff --git a/modules/bim/lib/open_project/bim/engine.rb b/modules/bim/lib/open_project/bim/engine.rb
index 09bafc05923..b75e0582e24 100644
--- a/modules/bim/lib/open_project/bim/engine.rb
+++ b/modules/bim/lib/open_project/bim/engine.rb
@@ -201,11 +201,9 @@ module OpenProject::Bim
config.to_prepare do
Doorkeeper.configuration.scopes.add(:bcf_v2_1)
- # rubocop:disable Lint/ConstantDefinitionInBlock
- module OpenProject::Authentication::Scope
- BCF_V2_1 = :bcf_v2_1
+ unless defined? OpenProject::Authentication::Scope::BCF_V2_1
+ OpenProject::Authentication::Scope::BCF_V2_1 = :bcf_v2_1
end
- # rubocop:enable Lint/ConstantDefinitionInBlock
OpenProject::Authentication.update_strategies(OpenProject::Authentication::Scope::BCF_V2_1,
store: false) do |_strategies|