Module: Saml::Kit::Validatable
- Extended by:
- ActiveSupport::Concern
- Includes:
- ActiveModel::Validations
- Included in:
- Document, Metadata, NullAssertion, Signature
- Defined in:
- lib/saml/kit/concerns/validatable.rb
Overview
This module is responsible for providing an adapter to the ActiveModel::Validations module.
Instance Method Summary collapse
Instance Method Details
#each_error ⇒ Object
12 13 14 15 16 17 18 19 20 21 22 |
# File 'lib/saml/kit/concerns/validatable.rb', line 12 def each_error if Gem::Requirement.new('>= 6.1').satisfied_by?(ActiveModel.version) errors.each do |error| yield error.attribute, error. end else errors.each do |attribute, | yield attribute, end end end |