Skip to content

Use wp_template_enhancement_output_buffer hook when available.#2514

Open
Hug0-Drelon wants to merge 2 commits into
WordPress:trunkfrom
Hug0-Drelon:fix-2224
Open

Use wp_template_enhancement_output_buffer hook when available.#2514
Hug0-Drelon wants to merge 2 commits into
WordPress:trunkfrom
Hug0-Drelon:fix-2224

Conversation

@Hug0-Drelon

@Hug0-Drelon Hug0-Drelon commented Jun 4, 2026

Copy link
Copy Markdown
Contributor

Summary

Fixes #2224

Relevant technical choices

Let's use wp_template_enhancement_output_buffer hook when available and remove od_buffer_output callback for template_include hook (since WP6.9).
Follows issue requirements.

Use of AI Tools

No AI on this one.

@Hug0-Drelon Hug0-Drelon requested a review from westonruter as a code owner June 4, 2026 12:56
@github-actions

github-actions Bot commented Jun 4, 2026

Copy link
Copy Markdown

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the props-bot label.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: Hug0-Drelon <hugod@git.wordpress.org>
Co-authored-by: westonruter <westonruter@git.wordpress.org>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

@codecov

codecov Bot commented Jun 4, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 66.66667% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 69.29%. Comparing base (a2815e6) to head (09e8184).
⚠️ Report is 6 commits behind head on trunk.

Files with missing lines Patch % Lines
plugins/optimization-detective/optimization.php 66.66% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##            trunk    #2514      +/-   ##
==========================================
- Coverage   69.29%   69.29%   -0.01%     
==========================================
  Files          90       90              
  Lines        7723     7725       +2     
==========================================
+ Hits         5352     5353       +1     
- Misses       2371     2372       +1     
Flag Coverage Δ
multisite 69.29% <66.66%> (-0.01%) ⬇️
single 35.75% <0.00%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Reuse template enhancement output buffer in Optimization Detective for WP 6.9

1 participant