put patches in a Patches modules

pull/6827/head
Martin Linkhorst 11 years ago
parent 9bd026745b
commit 14415bbd34
  1. 6
      lib/open_project/documents/patches/application_helper_patch.rb
  2. 6
      lib/open_project/documents/patches/custom_fields_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

@ -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

Loading…
Cancel
Save