mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Remove InstanceTagMethods module and define the methods inside the InstanceTag class
This commit is contained in:
parent
12f5158f09
commit
14198d84a9
1 changed files with 2 additions and 7 deletions
|
@ -858,8 +858,7 @@ module ActionView
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
module InstanceTagMethods #:nodoc:
|
class InstanceTag
|
||||||
extend ActiveSupport::Concern
|
|
||||||
include Helpers::CaptureHelper, Context, Helpers::TagHelper, Helpers::FormTagHelper
|
include Helpers::CaptureHelper, Context, Helpers::TagHelper, Helpers::FormTagHelper
|
||||||
|
|
||||||
attr_reader :object, :method_name, :object_name
|
attr_reader :object, :method_name, :object_name
|
||||||
|
@ -1025,7 +1024,7 @@ module ActionView
|
||||||
self.class.value_before_type_cast(object, @method_name)
|
self.class.value_before_type_cast(object, @method_name)
|
||||||
end
|
end
|
||||||
|
|
||||||
module ClassMethods
|
class << self
|
||||||
def value(object, method_name)
|
def value(object, method_name)
|
||||||
object.send method_name if object
|
object.send method_name if object
|
||||||
end
|
end
|
||||||
|
@ -1111,10 +1110,6 @@ module ActionView
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
class InstanceTag
|
|
||||||
include InstanceTagMethods
|
|
||||||
end
|
|
||||||
|
|
||||||
class FormBuilder
|
class FormBuilder
|
||||||
# The methods which wrap a form helper call.
|
# The methods which wrap a form helper call.
|
||||||
class_attribute :field_helpers
|
class_attribute :field_helpers
|
||||||
|
|
Loading…
Reference in a new issue