This repository has been archived by the owner on Feb 23, 2024. It is now read-only.
Compatibility Issue: woocommerce_before_thankyou Hook Passing Order Object Instead of Order ID #11851
Labels
priority: high
The issue/PR is high priority—it affects lots of customers substantially, but not critically.
type: bug
The issue/PR concerns a confirmed bug.
Describe the bug
The Order Confirmation Block passes an order object when it triggers the
woocommerce_before_thankyou
hook even though WooCommerce has always passed an order ID in thethankyou.php
template, which is now leading to type conflicts.To reproduce
Steps to reproduce the behavior:
Expected behavior
The expected behavior is for the
woocommerce_before_thankyou
hook to maintain backward compatibility by passing an order ID (integer).Environment
WordPress (please complete the following information):
Desktop (please complete the following information):
Additional context
We're running into this on a Team51 partner site. We noticed this issue when the Google Listings & Ads plugin threw a fatal after a recent WooCommerce update.
The text was updated successfully, but these errors were encountered: