delete_all_cache for destroy and not just ban

This commit is contained in:
Kyle Drake 2023-11-18 10:59:17 -06:00
parent 0f860cfdcc
commit 4c3daea4a8

View file

@ -504,6 +504,7 @@ class Site < Sequel::Model
def after_destroy
update_redis_proxy_record
delete_all_cache
end
def undelete!
@ -543,8 +544,6 @@ class Site < Sequel::Model
self.banned_at = Time.now
save validate: false
destroy
delete_all_cache
end
def ban_all_sites_on_account!
@ -989,11 +988,6 @@ class Site < Sequel::Model
parent_site_id.nil?
end
# def after_destroy
# FileUtils.rm_rf files_path
# super
# end
def ssl_installed?
!domain.blank? && !ssl_key.blank? && !ssl_cert.blank?
end