Hi,
the code you’ve shown does not show how you are creating or referencing the UContentBrowserAssetDataSource.
Could you show your startup/shutdownmodule implementation?
In general you’ll need to make sure you’re not keeping any UPROPERTY pointer or TStrongObjectPtr or similar reference if you want the object to be destroyed.
If you have a pointer in the module you might need to reset it manually, since the module would still exist, even if you manually call ShutdownModule() on it.
Also, why do you want to force destroy the data source?
Would shutting it down manually and then waiting for the next GC be an appropriate solution here?
Usually it’s a bit of a code smell trying to force delete a UObject, calling a some shutdown code to let the object clean up and unregister itself as a data source might be a better approach.
Kind Regards,
Sebastian