I had a couple communities show up that were purely unsolicited commercial messages for SEO purposes, so I used the following sql queries to thanos snap them out of existence.
delete from community_moderator where community = any( select id from community where name = 'ReplaceMe' );
delete from community_follow where community = any( select id from community where name = 'ReplaceMe' );
delete from notification where reply= any( select id FROM reply WHERE post = ANY( SELECT id FROM post WHERE community= any( select id from community where name = 'ReplaceMe' ) ));
DELETE FROM reply WHERE post = ANY( SELECT id FROM post WHERE community= any( select id from community where name = 'ReplaceMe' ) );
DELETE FROM notification WHERE parent_post = ANY( SELECT id FROM post WHERE community= any( select id from community where name = 'ReplaceMe' ) );
delete from community where name = 'ReplaceMe';
vpzom 1 year ago
note that if the communities have any followers, it's preferable to use the API/UI to delete communities so that the deletion federates
sj_zero@lotide.fbxl.net 1 year ago
(Hold on, is there an admin UI for this?)
vpzom 1 year ago
somewhat, there's a "delete community" link on the community's page if you're a moderator or side admin