Sha256: eef398401575b6381a09763aacc5b367b9fcead045935e395892c0bf1743f106
Contents?: true
Size: 584 Bytes
Versions: 9
Compression:
Stored size: 584 Bytes
Contents
# frozen_string_literal: true module Stance module ActiveRecordCallbacks extend ActiveSupport::Concern CALLBACKS = %i[after_initialize before_validation after_validation before_save before_create after_create before_update after_update before_destroy after_destroy after_save after_touch after_commit after_save_commit after_create_commit after_update_commit after_destroy_commit after_rollback].freeze included do CALLBACKS.each do |cb| send(cb) { publish_event cb } end end end end
Version data entries
9 entries across 9 versions & 1 rubygems