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

rely on now built in i18n behaviour

ulferts232ec48597fc
diff --git a/config/application.rb b/config/application.rb
index 01330dc5164..97f4e8f0c83 100644
--- a/config/application.rb
+++ b/config/application.rb
@@ -181,6 +181,8 @@ module OpenProject
# Enable cascade key lookup for i18n
I18n.backend.class.send(:include, I18n::Backend::Cascade)
+ ActiveModel::Translation.raise_on_missing_translations = Rails.env.local?
+
# Configure the default encoding used in templates for Ruby 1.9.
config.encoding = "utf-8"
diff --git a/lib/open_project/patches/active_record_i18n.rb b/lib/open_project/patches/active_record_i18n.rb
index cc0beab8a76..301ee5a4901 100644
--- a/lib/open_project/patches/active_record_i18n.rb
+++ b/lib/open_project/patches/active_record_i18n.rb
@@ -37,12 +37,6 @@ module ActiveRecord
options[:default] ||= :"activerecord.models.#{attr}"
- if Rails.env.local?
- def attr.humanize(*)
- raise ArgumentError, "I18n translation missing for attribute #{self}"
- end
- end
-
super
end
end