instance method inherited

Ruby on Rails 3.1.12

Since v3.0.20 Last seen in v3.2.22.5

Available in: v3.0.20 v3.1.12 v3.2.22.5

Signature

inherited(base)

Copy validators on inheritance.

Parameters

base req
Source
# File activemodel/lib/active_model/validations.rb, line 161
      def inherited(base)
        dup = _validators.dup
        base._validators = dup.each { |k, v| dup[k] = v.dup }
        super
      end

Defined in activemodel/lib/active_model/validations.rb line 161 · View on GitHub · Improve this page · Find usages on GitHub

Defined in ActiveModel::Validations::ClassMethods

Type at least 2 characters to search.

↑↓ navigate · open · esc close