Class: AttrMasker::Performer::ActiveRecord
- Inherits:
-
Object
- Object
- AttrMasker::Performer::ActiveRecord
- Defined in:
- lib/attr_masker/performer.rb
Instance Method Summary collapse
Instance Method Details
#mask ⇒ Object
6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
# File 'lib/attr_masker/performer.rb', line 6 def mask unless defined? ::ActiveRecord raise AttrMasker::Error, "ActiveRecord undefined. Nothing to do!" end # Do not want production environment to be masked! # if Rails.env.production? raise AttrMasker::Error, "Attempted to run in production environment." end all_models.each do |klass| next if klass.masker_attributes.empty? mask_class(klass) end end |