Module: Anony::Config
- Defined in:
- lib/anony/config.rb
Overview
Configuration which modifies how the gem will behave in your application. It’s recommended practice to configure this in an initializer.
Class Method Summary collapse
-
.ignore_fields(*fields) ⇒ Object
A list of database or model properties to be ignored when anonymising.
Class Method Details
.ignore_fields(*fields) ⇒ Object
A list of database or model properties to be ignored when anonymising. This is helpful in Rails applications when there are common columns such as ‘id`, `created_at` and `updated_at`, which we would never want to try and anonymise.
By default, this is an empty collection (i.e. no fields are ignored).
36 37 38 |
# File 'lib/anony/config.rb', line 36 def self.ignore_fields(*fields) self.ignores = Array(fields) end |