app/models/journaled/audit_log/event.rb in journaled-5.1.0 vs app/models/journaled/audit_log/event.rb in journaled-5.1.1

- old
+ new

@@ -1,17 +1,21 @@ # FIXME: This cannot be included in lib/ because Journaled::Event is autoloaded via app/models # Autoloading Journaled::Event isn't strictly necessary, and for compatibility it would # make sense to move it to lib/. module Journaled module AuditLog - Event = Struct.new(:record, :database_operation, :unfiltered_changes) do + Event = Struct.new(:record, :database_operation, :unfiltered_changes, :enqueue_opts) do include Journaled::Event journal_attributes :class_name, :table_name, :record_id, :database_operation, :changes, :snapshot, :actor, tagged: true def journaled_stream_name AuditLog.default_stream_name || super + end + + def journaled_enqueue_opts + record.class.audit_log_config.enqueue_opts end def created_at case database_operation when 'insert'