Skip to content
This repository has been archived by the owner on Feb 23, 2024. It is now read-only.

Fix arguments passed to woocommerce_before_thankyou to mirror core hook #11862

Merged
merged 1 commit into from
Nov 21, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/BlockTypes/OrderConfirmation/Status.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ protected function render_content( $order, $permission = false, $attributes = []
return '<p>' . wp_kses_post( apply_filters( 'woocommerce_thankyou_order_received_text', esc_html__( 'Thank you. Your order has been received.', 'woo-gutenberg-products-block' ), null ) ) . '</p>';
}

$content = $this->get_hook_content( 'woocommerce_before_thankyou', [ $order ] );
$content = $this->get_hook_content( 'woocommerce_before_thankyou', [ $order->get_id() ] );
$status = $order->get_status();

// Unlike the core handling, this includes some extra messaging for completed orders so the text is appropriate for other order statuses.
Expand Down
Loading