Hi,
I have a website hosted on Kinsta. I had updated my SSL, and after the update, some of the images went missing from the website. I thought it might be some URL issue related to HTTP to HTTPS. But that was not the issue.
When I checked my media library, images were also missing from there. So, I consulted with my hosting provider, and they told me that there is a CRON job setup by WPDiscuz. It runs once every 48 hours. So, I checked the code, which is done to delete the unattached images.
Now, I think that WordPress does not show the exact results of attached or unattached images. Is it possible that my images got deleted from the media library due to this functionality? Can you please confirm if this could be the reason, or could there be any other plugin that caused the issue? If this functionality is the root cause, can you also let me know how to disable this functionality?
Please let us know the versions of the wpDiscuz and wpDiscuz Media Uploader plugins you're using?
In case you want to say thank you! 🙂
We'd really appreciate if you leave a good review on the plugin page.
This is the best way to say thank you to this project and the support team.
Hi, I am using the wpDiscuz version 7.3.17.
And don't you use the wpDiscuz Media Uploader addon?
In case you want to say thank you! 🙂
We'd really appreciate if you leave a good review on the plugin page.
This is the best way to say thank you to this project and the support team.
In any case, you can use the following hook code if somehow you've faced the issue:
add_filter('wpdiscuz_delete_unattached_files', '__return_false');
This article should be helpful for you: https://www.wpbeginner.com/plugins/how-to-easily-add-custom-code-in-wordpress-without-breaking-your-site/
In case you want to say thank you! 🙂
We'd really appreciate if you leave a good review on the plugin page.
This is the best way to say thank you to this project and the support team.
@asti No
Doesn't the code help you?
In case you want to say thank you! 🙂
We'd really appreciate if you leave a good review on the plugin page.
This is the best way to say thank you to this project and the support team.

