MyBB-Plugins Forums
MyBB Purge Spammer -change permadelete to softdelete? - Printable Version

+- MyBB-Plugins Forums (http://forums.mybb-plugins.com)
+-- Forum: MyBB General Discussion (http://forums.mybb-plugins.com/Forum-MyBB-General-Discussion)
+--- Forum: Coding Help (http://forums.mybb-plugins.com/Forum-Coding-Help)
+--- Thread: MyBB Purge Spammer -change permadelete to softdelete? (/Thread-MyBB-Purge-Spammer-change-permadelete-to-softdelete)



MyBB Purge Spammer -change permadelete to softdelete? - Darrakas - 06-08-2016

Hey. It would be really useful to have option to choose, does "Purge Spammer" button permadelete every posts/threads made by the user or does it only softdelete those.
I used the Purge button earlier, but our moderators are humans and humans make mistakes. But if they purged a member by a mistake, we can't recover the member's threads & posts anymore because that Purge Spammer -button permadeletes everything.

I want to change only the threads/posts deleting option from permadelete to softdelete so we may restore member's threads if mistake were made. Currently i disabled that Purge Spammer button, but it really makes moderating job easier.

I spent time to google about if anyone other wanted to do the same change, but i couldn't find anything.


RE: MyBB Purge Spammer -change permadelete to softdelete? - Diogo Parrinha - 06-08-2016

You can set a post limit for purge spammer IIRC. So if a user has over 5 posts for example, purge spammer won't be shown anymore.


RE: MyBB Purge Spammer -change permadelete to softdelete? - Darrakas - 06-11-2016

Yes, i know that there is a such option, but you did not answer to the question (I was maybe unclear);

How can i change the Purge Spammer -button action to softdelete posts & threads instead of permadeleting those.


RE: MyBB Purge Spammer -change permadelete to softdelete? - Diogo Parrinha - 06-11-2016

You'd have to look into the code and find the place where it deletes the posts/threads and see what's going on. If it uses the default MyBB moderation class to delete it, then you can easily change it to soft_delete by using the respective methods.

This forum is not for me to code things for people, it's to help them with coding problems they may have.


RE: MyBB Purge Spammer -change permadelete to softdelete? - Darrakas - 06-13-2016

(06-11-2016, 10:01 PM)Diogo Parrinha Wrote: You'd have to look into the code and find the place where it deletes the posts/threads and see what's going on. If it uses the default MyBB moderation class to delete it, then you can easily change it to soft_delete by using the respective methods.

This forum is not for me to code things for people, it's to help them with coding problems they may have.

Thank you.
No, i don't ask you to code me anything, i just want to know where that part of code can be and how is it possible to change. Probably need to go trough all those files.
I found the place where the delete action is handled, its in moderation.php (http://i.imgur.com/t6TpJTw.png).

Thanks Smile!
This thread can be closed.


RE: MyBB Purge Spammer -change permadelete to softdelete? - Diogo Parrinha - 06-13-2016

Yes, now you just need to replace by soft delete Smile