Drop guest checkout test and only check if order is for guest
This commit is contained in:
parent
c3bc0e61a7
commit
5f3f7e5bb1
|
@ -300,7 +300,7 @@ function wc_customer_has_capability( $allcaps, $caps, $args ) {
|
|||
}
|
||||
|
||||
$order = new WC_Order( $order_id );
|
||||
if ( $user_id == $order->user_id || empty( $order->user_id ) || 'yes' == get_option( 'woocommerce_enable_guest_checkout' ) ) {
|
||||
if ( $user_id == $order->user_id || empty( $order->user_id ) ) {
|
||||
$allcaps['pay_for_order'] = true;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue