Module: Tracer::Changes

Defined in:
lib/tracer_client/changes.rb

Defined Under Namespace

Modules: ClassMethods, InstanceMethods

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.included(base) ⇒ Object



6
7
8
# File 'lib/tracer_client/changes.rb', line 6

def self.included(base)
  base.send :extend, ClassMethods
end

Instance Method Details

#log_changes?Boolean

Returns:

  • (Boolean)


168
169
170
171
172
# File 'lib/tracer_client/changes.rb', line 168

def log_changes?
  if_condition     = self.changes_logging_options[:if]
  unless_condition = self.changes_logging_options[:unless]
  (if_condition.blank? || if_condition.call(self)) && !unless_condition.try(:call, self)
end