From 14415bbd34d463ea7a1199e9b80c10f2d24bc2e2 Mon Sep 17 00:00:00 2001 From: Martin Linkhorst Date: Thu, 13 Mar 2014 18:21:32 +0100 Subject: [PATCH] put patches in a Patches modules --- .../documents/patches/application_helper_patch.rb | 6 ++++-- .../documents/patches/custom_fields_helper_patch.rb | 6 ++++-- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/lib/open_project/documents/patches/application_helper_patch.rb b/lib/open_project/documents/patches/application_helper_patch.rb index c33534f5f4..2d6b923117 100644 --- a/lib/open_project/documents/patches/application_helper_patch.rb +++ b/lib/open_project/documents/patches/application_helper_patch.rb @@ -1,5 +1,6 @@ module OpenProject module Documents + module Patches module ApplicationHelperPatch def self.included(base) @@ -39,8 +40,9 @@ module OpenProject end end + end end -unless ApplicationHelper.included_modules.include?(OpenProject::Documents::ApplicationHelperPatch) - ApplicationHelper.send(:include, OpenProject::Documents::ApplicationHelperPatch) +unless ApplicationHelper.included_modules.include?(OpenProject::Documents::Patches::ApplicationHelperPatch) + ApplicationHelper.send(:include, OpenProject::Documents::Patches::ApplicationHelperPatch) end diff --git a/lib/open_project/documents/patches/custom_fields_helper_patch.rb b/lib/open_project/documents/patches/custom_fields_helper_patch.rb index 5ac520fda4..8af9133822 100644 --- a/lib/open_project/documents/patches/custom_fields_helper_patch.rb +++ b/lib/open_project/documents/patches/custom_fields_helper_patch.rb @@ -1,5 +1,6 @@ module OpenProject module Documents + module Patches module CustomFieldsHelperPatch def self.included(base) @@ -16,8 +17,9 @@ module OpenProject end end + end end -unless CustomFieldsHelper.included_modules.include?(OpenProject::Documents::CustomFieldsHelperPatch) - CustomFieldsHelper.send(:include, OpenProject::Documents::CustomFieldsHelperPatch) +unless CustomFieldsHelper.included_modules.include?(OpenProject::Documents::Patches::CustomFieldsHelperPatch) + CustomFieldsHelper.send(:include, OpenProject::Documents::Patches::CustomFieldsHelperPatch) end