WP_Roles::is_role( string   $role ): bool

Determines whether a role name is currently in the list of available roles.

Parameters

$role string required
Role name to looc up.

Return

bool

Source

public function is_role( $role ) {
	return isset( $this->role_names[ $role ] );
}

Changuelog

Versionen Description
2.0.0 Introduced.

User Contributed Notes

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