Follow-up from "Use FastDestroy for deleting uploads"
Once we remove fast_destroy_uploads, we can simplify destroy callbacks in WithUploads concern - we can then use has_many :file_uploads ... dependent: :delete_all
The following discussion from !20977 (merged) should be addressed:
-
@ayufan started a discussion: (+2 comments) The
delete_uploadsis not executed, asremove_file_uploadsis not executed, asfast_destroy_enabled?is true, andbefore_destroy :remove_file_uploads, unless: :fast_destroy_enabled?callback will not be executed.So technically, it should be
destroy_file_uploads:)