Property | Type | Description | |
---|---|---|---|
$caps | array | User capabilities | |
$data | array | User profile data | |
$is_member | boolean | Whether or not the user requested is a member of Awesome Support | |
$roles | array | User roles | |
$user_id | integer | User ID |
Method | Description | |
---|---|---|
__construct ( integer | stdClass $user ) | WPAS_Member constructor. | |
has_cap ( string $cap ) : boolean | Check if the user has a specific capability | |
is_member ( ) : boolean | Check if the current user actually is an Awesome Support member |
Method | Description | |
---|---|---|
data_defaults ( ) : array | Get the default profile data fields | |
get_user_data ( $user_id ) : array | Get user data by user ID | |
init ( $data ) : void | Setup the user data | |
setup_caps ( ) : void | Setup the user capabilities based on their roles | |
setup_roles ( ) : void | Setup the user roles |
public __construct ( integer | stdClass $user ) | ||
$user | integer | stdClass | The user ID or stdClass |
protected data_defaults ( ) : array | ||
return | array |
protected get_user_data ( $user_id ) : array | ||
$user_id | ||
return | array |
protected setup_caps ( ) : void | ||
return | void |
public bool $is_member | ||
return | boolean |