Warning: Array to string conversion in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 825

Warning: foreach() argument must be of type array|object, string given in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 830

Warning: Array to string conversion in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 825

Warning: foreach() argument must be of type array|object, string given in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 830
PeepSo_Helpers::get_gender( $user_id )


Warning: Array to string conversion in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 825

Warning: foreach() argument must be of type array|object, string given in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 830

Warning: Array to string conversion in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 825

Warning: foreach() argument must be of type array|object, string given in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 830

Parameters Parameters

(Required) gender of the follower

$user_id

(Required)


Source Source

File: src/integrations/peepso/helpers/peepso-helpers.php

	public function get_gender( $user_id ) {
		if ( empty( $user_id ) ) {
			return;
		}
		$gender = get_user_meta( $user_id, 'peepso_user_field_gender', true );
		$acc    = get_user_meta( $user_id, 'peepso_user_field_gender_acc', true );
		if ( $gender === 'm' && $acc >= 0 ) {
			return 'Male';
		} elseif ( $gender === 'f' && $acc >= 0 ) {
			return 'Female';
		}
	}