bp_user_has_opted_out( string $email_address = '' )

Check an email address to see if that individual has opted out.


Parameters Parameters

$email_address

(string) (Optional) Email address to check.

Default value: ''


Top ↑

Return Return

(bool) True if the user has opted out, false otherwise.


Source Source

File: bp-core/bp-core-functions.php

function bp_user_has_opted_out( $email_address = '' ) {
	$optout_class = new BP_Optout();
	$optout_id    = $optout_class->optout_exists(
		array(
			'email_address' => $email_address,
		)
	);
	return (bool) $optout_id;
}


Top ↑

Changelog Changelog

Changelog
Version Description
8.0.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.