Sha256: 01223fb4b3763cadc2fb7856024aaec5a6d32360d0f0f59b66b3c1de35dca3c2

Contents?: true

Size: 341 Bytes

Versions: 2

Compression:

Stored size: 341 Bytes

Contents

# frozen_string_literal: true

module Mongoid
module Orderable
module Mixins
  # This is required to trigger callbacks on embedded objects.
  # Otherwise, the #move_to parameter won't work when saving the parent.
  module Cascadeable
    def in_callback_state?(kind)
      super || move_all.present?
    end
  end
end
end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
mongoid_orderable-6.0.5 lib/mongoid/orderable/mixins/cascadeable.rb
mongoid_orderable-6.0.4 lib/mongoid/orderable/mixins/cascadeable.rb