2020-04-29 15:30:44 +01:00

14 lines
368 B
Ruby

require 'active_support/notifications'
module FastJsonapi
module ObjectSerializer
alias serializable_hash_without_instrumentation serializable_hash
def serializable_hash
ActiveSupport::Notifications.instrument(SERIALIZABLE_HASH_NOTIFICATION, { name: self.class.name }) do
serializable_hash_without_instrumentation
end
end
end
end