Class: ActiveStorageValidations::WithAudioValidator
- Inherits:
-
ActiveModel::EachValidator
- Object
- ActiveModel::EachValidator
- ActiveStorageValidations::WithAudioValidator
- Defined in:
- lib/active_storage_validations/with_audio_validator.rb
Overview
:nodoc
Constant Summary collapse
- ERROR_TYPES =
%i[audio_missing audio_present].freeze
- METADATA_KEYS =
%i[audio].freeze
Constants included from ASVAnalyzable
ASVAnalyzable::DEFAULT_IMAGE_PROCESSOR
Instance Method Summary collapse
Methods included from ASVErrorable
#add_error, #initialize_error_options
Instance Method Details
#validate_each(record, attribute, _value) ⇒ Object
20 21 22 23 24 |
# File 'lib/active_storage_validations/with_audio_validator.rb', line 20 def validate_each(record, attribute, _value) return if (record, attribute) (record, attribute, METADATA_KEYS) end |