HomePhabricator
Delete All Moderation Queue

USE hunsa;
INSERT INTO xf_deletion_log (content_type, content_id, delete_date, delete_user_id, delete_username, delete_reason)
	SELECT content_type, content_id, UNIX_TIMESTAMP(), 1, 'admin', 'manually moved from moderation to soft delete'
	FROM xf_moderation_queue AS mq
	WHERE mq.content_type = 'thread';

DELETE
FROM xf_moderation_queue
WHERE content_type = 'thread';

UPDATE xf_thread
SET discussion_state = 'deleted'
WHERE discussion_state = 'moderated';


INSERT INTO xf_deletion_log (content_type, content_id, delete_date, delete_user_id, delete_username, delete_reason)
	SELECT content_type, content_id, UNIX_TIMESTAMP(), 1, 'admin', 'manually moved from moderation to soft delete'
	FROM xf_moderation_queue AS mq
	WHERE mq.content_type = 'post';

DELETE
FROM xf_moderation_queue
WHERE content_type = 'post';

UPDATE xf_post
SET message_state = 'deleted'
WHERE message_state = 'moderated';

DELETE
FROM xf_data_registry
WHERE data_key = 'moderationCounts';
Written by vorapoap on May 9 2019, 1:38 PM.
User
Projects
None
Subscribers
None
Tokens
"Like" token, awarded by apiwat.

Event Timeline