Hi, I'm looking for ways to check if email already exists when a user sign in.
I saw the documentation and found:
do_action( 'rwmb_profile_before_save_user', $object );
but I do not know how to use this action to make a check like this:
$email = '[email protected]';
$exists = email_exists( $email );
if ( $exists ) {
echo 'That E-mail is registered to user number ' . esc_html( $exists );
} else {
echo 'That E-mail doesn\'t belong to any registered users on this site';
}