Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/paranoia.rb
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ def really_destroy!
association_data.really_destroy!
end
end
write_attribute(paranoia_column, current_time_from_proper_timezone)
assign_attributes(paranoia_destroy_attributes)
destroy_without_paranoia
end
end
Expand Down
6 changes: 6 additions & 0 deletions test/paranoia_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -489,6 +489,12 @@ def test_really_destroy
refute ParanoidModel.unscoped.exists?(model.id)
end

def test_really_destroy_for_active_column_model
model = ActiveColumnModel.create
model.really_destroy!
refute ActiveColumnModel.unscoped.exists?(model.id)
end

def test_real_destroy_dependent_destroy
parent = ParentModel.create
child1 = parent.very_related_models.create
Expand Down