📅  最后修改于: 2022-03-11 14:54:07.976000             🧑  作者: Mango
global $current_user;
get_currentuserinfo();
if ( $current_user ) {
$permission = get_user_meta( $current_user->ID, 'some_meta' , true );
if ( ! empty( $permission ) ) {
// do stuff
}
}
// works for both array and single values