Skip to content

Commit

Permalink
using miss hannigan to nullify child to parent relationship before de…
Browse files Browse the repository at this point in the history
…stroy
  • Loading branch information
Kat-Alo committed Oct 10, 2023
1 parent 54f8219 commit 8f9f1d3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/models/page.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
class Page < ApplicationRecord
belongs_to :user

has_many :page_snapshots, dependent: :destroy
has_many :page_snapshots, dependent: :nullify_then_purge

attr_accessor :subscriptions # Gets set in controller on update/create
after_create :update_subscriptions
Expand Down

0 comments on commit 8f9f1d3

Please sign in to comment.