method

setup!

Importance_0
setup!(klass) private

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File activemodel/lib/active_model/validations/confirmation.rb, line 21
        def setup!(klass)
          klass.attr_reader(*attributes.map do |attribute|
            :"#{attribute}_confirmation" unless klass.method_defined?(:"#{attribute}_confirmation")
          end.compact)

          klass.attr_writer(*attributes.map do |attribute|
            :"#{attribute}_confirmation" unless klass.method_defined?(:"#{attribute}_confirmation=")
          end.compact)
        end
Register or log in to add new notes.