... $filter ); if ( ! current_user_can( 'read_private_shop_orders' ) ) { return new WP_Error( 'woocommerce_api_user_cannot_read_orders_count', ...
... WP_Error( 'woocommerce_api_user_cannot_read_orders_count', __( 'You do not have permission to read the orders count', 'woocommerce' ), array( 'status' ...