ssor( OrderLogsDeletionProcessor::class ); } } // Prevent further logging for this request. $order = null; $logging_active = false; $steps = array(); } } catch ( Exception $e ) { // phpcs:ignore Generic.CodeAnalysis.EmptyStatement.DetectedCatch // Since this runs in a critical path, we need to catch any exceptions and ignore them. } } /** * Extract safe data from order object for debug temporary logging. * * @param WC_Order $order Order object. * * @internal This function is intended for internal use only. * @since 9.9.0 */ function extract_order_safe_data( WC_Order $order ) { $order_data = array( 'order_id' => $order->get_id(), 'payment_method' => $order->get_payment_method_title(), 'billing' => array( 'country' => $order->get_billing_country(), 'state' => $order->get_billing_state(), ), 'shipping' => array( 'country' => $order->get_shipping_country(), 'state' => $order->get_shipping_state(), ), 'used_coupons' => $order->get_coupon_codes(), 'totals' => array( 'subtotal' => $order->get_subtotal(), 'shipping' => $order->get_shipping_total(), 'tax' => $order->get_total_tax(), 'discount' => $order->get_discount_total(), 'total' => $order->get_total(), ), ); // Add tax breakdown. foreach ( $order->get_tax_totals() as $tax ) { $order_data['totals']['tax_breakdown'][ $tax->label ] = $tax->amount; } // Add cart items and quantities. foreach ( $order->get_items() as $item_id => $item ) { $order_data['cart_items'][] = array( 'id' => $item_id, 'product_id' => $item->get_product_id(), 'variation_id' => $item->get_variation_id(), 'quantity' => $item->get_quantity(), ); } // Add Shipping methods used. foreach ( $order->get_shipping_methods() as $method ) { $order_data['shipping_methods'][] = array( 'id' => $method->get_method_id(), 'label' => $method->get_method_title(), ); } return $order_data; }
Fatal error: Uncaught Error: Class "Automattic\WooCommerce\Blocks\BlockTypes\Reviews\ProductReviewsTitle" not found in /htdocs/wp-content/plugins/woocommerce/src/Blocks/BlockTypesController.php:118 Stack trace: #0 /htdocs/wp-includes/class-wp-hook.php(341): Automattic\WooCommerce\Blocks\BlockTypesController->register_blocks('') #1 /htdocs/wp-includes/class-wp-hook.php(365): WP_Hook->apply_filters(NULL, Array) #2 /htdocs/wp-includes/plugin.php(522): WP_Hook->do_action(Array) #3 /htdocs/wp-settings.php(742): do_action('init') #4 /htdocs/wp-config.php(98): require_once('/htdocs/wp-sett...') #5 /htdocs/wp-load.php(50): require_once('/htdocs/wp-conf...') #6 /htdocs/wp-blog-header.php(13): require_once('/htdocs/wp-load...') #7 /htdocs/index.php(17): require('/htdocs/wp-blog...') #8 {main} thrown in /htdocs/wp-content/plugins/woocommerce/src/Blocks/BlockTypesController.php on line 118