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
hacks the hacky hacksaw
Marcello Rocha9ffe495b984a
diff --git a/spec/support/i18n_lazy_loading.rb b/spec/support/i18n_lazy_loading.rbindex ca0a62c6556..0a06b436049 100644--- a/spec/support/i18n_lazy_loading.rb+++ b/spec/support/i18n_lazy_loading.rb@@ -28,16 +28,19 @@# Lazy loads translations based on the current locale.# It avoids a 2 to 4 seconds penalty when all locales are loaded.-I18n.backend = I18n::Backend::LazyLoadable.new(lazy_load: true)-# Need to make LocaleExtractor recognize our js-<locale>.yaml file format-module LocaleExtractorPatch++require "i18n/backend/lazy_loadable"++class I18n::Backend::LocaleExtractordef self.locale_from_path(path)- locale = super- locale.to_s.delete_prefix("js-").to_sym if locale- # name = File.basename(path, ".*")- # locale = name.split("_").first.delete_prefix("js-")- # locale&.to_sym+ name = File.basename(path, ".*")+ locale = name.split("_").first++ return if locale.nil?++ locale.tr("js-", "").to_symendend-I18n::Backend::LocaleExtractor.prepend(LocaleExtractorPatch)++I18n.backend = I18n::Backend::LazyLoadable.new(lazy_load: true)