Class: OrderCop::OrderCopConfig
- Inherits:
-
Object
- Object
- OrderCop::OrderCopConfig
- Defined in:
- lib/order_cop.rb
Instance Attribute Summary collapse
-
#debug ⇒ Object
Returns the value of attribute debug.
-
#enabled ⇒ Object
Returns the value of attribute enabled.
-
#only_view ⇒ Object
Returns the value of attribute only_view.
-
#rails_logger ⇒ Object
Returns the value of attribute rails_logger.
-
#raise ⇒ Object
Returns the value of attribute raise.
-
#view_paths ⇒ Object
Returns the value of attribute view_paths.
-
#whitelist_methods ⇒ Object
Returns the value of attribute whitelist_methods.
Instance Method Summary collapse
-
#initialize ⇒ OrderCopConfig
constructor
A new instance of OrderCopConfig.
Constructor Details
#initialize ⇒ OrderCopConfig
Returns a new instance of OrderCopConfig.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 |
# File 'lib/order_cop.rb', line 16 def initialize @enabled = true @raise = true @debug = false @rails_logger = false @whitelist_methods = %i[sum any? none? inspect method_missing not load_target reindex attachment attachments attributes_table with_current_arbre_element] @only_view = false @view_paths = [ /app\/views/, /app\/helpers/, /\.erb/, /\.haml/, /\.slim/, /\(erb\)/ ].freeze end |
Instance Attribute Details
#debug ⇒ Object
Returns the value of attribute debug.
32 33 34 |
# File 'lib/order_cop.rb', line 32 def debug @debug end |
#enabled ⇒ Object
Returns the value of attribute enabled.
32 33 34 |
# File 'lib/order_cop.rb', line 32 def enabled @enabled end |
#only_view ⇒ Object
Returns the value of attribute only_view.
32 33 34 |
# File 'lib/order_cop.rb', line 32 def only_view @only_view end |
#rails_logger ⇒ Object
Returns the value of attribute rails_logger.
32 33 34 |
# File 'lib/order_cop.rb', line 32 def rails_logger @rails_logger end |
#raise ⇒ Object
Returns the value of attribute raise.
32 33 34 |
# File 'lib/order_cop.rb', line 32 def raise @raise end |
#view_paths ⇒ Object
Returns the value of attribute view_paths.
32 33 34 |
# File 'lib/order_cop.rb', line 32 def view_paths @view_paths end |
#whitelist_methods ⇒ Object
Returns the value of attribute whitelist_methods.
32 33 34 |
# File 'lib/order_cop.rb', line 32 def whitelist_methods @whitelist_methods end |