lib/shamu/auditing/logging_auditing_service.rb in shamu-0.0.15 vs lib/shamu/auditing/logging_auditing_service.rb in shamu-0.0.17

- old
+ new

@@ -1,13 +1,15 @@ module Shamu module Auditing # Writes audit logs to the {Shamu::Logger}. - class LoggingAuditingService < Services::Service + class LoggingAuditingService < AuditingService - # (see AuditingService#commit) + # Records an auditable event in persistent storage. + # @param [Transaction] transaction + # @return [AuditRecord] the persisted record. def commit( transaction ) - logger.unknown "AUDIT TRANSACTION action: #{ transaction.action } entity: #{ transaction.entity_path } by user: #{ transaction.user_id_chain } changes: #{ transaction.changes }" # rubocop:disable Metrics/LineLength + logger.unknown "AUDIT TRANSACTION action: #{ transaction.action } entity: #{ transaction.entity_path } by user: #{ transaction.user_id_chain } changes: #{ filter_changes( transaction.changes ) }" # rubocop:disable Metrics/LineLength end end end end