How can I add the current Wordpress users Email Address into my code below? This is for the theme functions theme.
add_filter( 'facetwp_preload_url_vars', function( $url_vars ) {
if ( 'directory/page' == FWP()->helper->get_uri() ) {
if ( empty( $url_vars['email_address'] ) ) {
$url_vars['email_address'] = array( 'INSERT CURRENT USER EMAIL ADDRESS' );
}
}
return $url_vars;
} );
Currently: INSERT CURRENT USER EMAIL ADDRESS Needed Example: forexample@domain.com