buddypress/tests/phpunit/testcases
Mathieu Viet 9b4a98cb20 Ensure cached data is cleared in BP_XProfile_ProfileData::delete_data_for_user().
Data was being deleted in bulk using a direct SQL query, bypassing the `xprofile_data_before_delete` and `xprofile_data_after_delete` actions, resulting in stale data persisting in the xprofile cache. This change uses `xprofile_delete_field_data()` to delete the user's data so that the action hooks are called.

Props dd32, r-a-y, dcavins.

See #8388 (branch 6.0).


git-svn-id: https://buddypress.svn.wordpress.org/branches/6.0@12785 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
2020-11-11 23:29:36 +00:00
..
activity Adapt BuddyPress to WP 5.1.0 multisite changes & deprecations 2020-03-31 02:45:13 +00:00
admin Retire Legacy Forums. 2017-12-08 00:22:09 +00:00
blogs Adapt BuddyPress to WP 5.1.0 multisite changes & deprecations 2020-03-31 02:45:13 +00:00
core Prepare the inclusion of the BP REST API remaining endpoints 2020-03-31 11:33:35 +00:00
friends Don't delete user data on delete_user hook on Multisite. 2020-03-29 17:32:05 +00:00
groups Don't delete user data on delete_user hook on Multisite. 2020-03-29 17:32:05 +00:00
members Members: When marking a user as a spammer, do not mark sites as spam if the site has more than one administrator. 2020-06-16 04:31:11 +00:00
messages Make sure Messages exports only include the ones sent by the user 2019-06-17 17:43:50 +00:00
notifications Don't delete user data on delete_user hook on Multisite. 2020-03-29 17:32:05 +00:00
routing Adapt BuddyPress to WP 5.1.0 multisite changes & deprecations 2020-03-31 02:45:13 +00:00
settings Improve sanitization of email notification settings. 2015-11-11 03:22:53 +00:00
testsuite Use static factory method throughout PHPUnit tests. 2017-11-03 19:44:10 +00:00
xprofile Ensure cached data is cleared in BP_XProfile_ProfileData::delete_data_for_user(). 2020-11-11 23:29:36 +00:00