Filter to modify the directory query?
-
Hi everyone,
I’m trying to modify the query of the Ultimate Member members directory to log something simple, like user IDs, just to understand how to use the correct filter.
I’ve tried using
um_prepare_user_query_args
, but I don’t see it working. Here’s the minimal code I’m using in my function.php:add_filter('um_prepare_user_query_args', 'test_user_directory_query', 10, 2);
function test_user_directory_query($args, $directory_data) {
error_log('Filter applied to the user query.');
return $args;
}However, nothing shows up in the error log, so it seems like the filter isn’t being applied. Is this the right filter to modify the members directory query? If not, what’s the correct filter for that?
Ultimately, I want to exclude users who are not verified and registered after a specific date.
Thanks in advance for any help!
- You must be logged in to reply to this topic.