ElasticPressLabs icon indicating copy to clipboard operation
ElasticPressLabs copied to clipboard

To add ep_user_sync_kill filter when user meta updated

Open yarovikov opened this issue 2 months ago • 1 comments

Is your enhancement related to a problem? Please describe.

Hi there

What about to add ep_user_sync_kill

if ( apply_filters( 'ep_user_sync_kill', false, $user_id ) ) {
    return;
}

here

https://github.com/10up/ElasticPressLabs/blob/develop/includes/classes/Indexable/User/SyncManager.php#L66

I don't need some users in the index after updating their metadata. Related with https://github.com/10up/ElasticPressLabs/issues/162

Designs

No response

Describe alternatives you've considered

No response

Code of Conduct

  • [x] I agree to follow this project's Code of Conduct

yarovikov avatar Nov 13 '25 05:11 yarovikov

That makes total sense, @yarovikov. Even better if we could add ep_user_sync_kill and something like ep_skip_user_meta_sync, based on the similar filter we have for posts here.

Do you want to craft a PR with that addition?

felipeelia avatar Nov 13 '25 11:11 felipeelia