Sha256: 19b650efebf89b20011091409c9d1d6277d283eb46220b47146989cd0c134dbc
Contents?: true
Size: 590 Bytes
Versions: 5
Compression:
Stored size: 590 Bytes
Contents
module EitilSupport::Stack::Audit extend ActiveSupport::Concern included do private after_update :add_stacktrace_to_audit def add_stacktrace_to_audit # .report_app_calls filters the stack on calls whose path include "/app/", since # audits otherwise tend to grow very big, which might endanger the database. stacktrace = EitilSupport::Stack.new.report_app_calls # Safe operator in order to avoid raising a NoMetodError when the record # has no audits yet. self.audits.last&.update(stacktrace: stacktrace) end end end
Version data entries
5 entries across 5 versions & 1 rubygems