Class: BetterRecord::AttachmentValidation
- Defined in:
- app/models/better_record/attachment_validation.rb
Class Method Summary collapse
-
.delete_invalid ⇒ Object
Class Methods ========================================================.
Methods inherited from Base
#dup, gender_enum, get_hashed_string, #get_hashed_string, #indifferent_attributes, set_audit_methods!
Class Method Details
.delete_invalid ⇒ Object
Class Methods ========================================================
31 32 33 34 35 |
# File 'app/models/better_record/attachment_validation.rb', line 31 def self.delete_invalid BetterRecord::AttachmentValidation. where.not( id: BetterRecord::AttachmentValidation.joins(:attachment).select(:id) ). delete_all end |