Shortcode: Fix broken Youtube URL on Classic Editor#46433
Conversation
|
Are you an Automattician? Please test your changes on all WordPress.com environments to help mitigate accidental explosions.
Interested in more tips and information?
|
|
Thank you for your PR! When contributing to Jetpack, we have a few suggestions that can help us test and review your patch:
This comment will be updated as you work on your PR and make changes. If you think that some of those checks are not needed for your PR, please explain why you think so. Thanks for cooperation 🤖 Follow this PR Review Process:
If you have questions about anything, reach out in #jetpack-developers for guidance! Jetpack plugin: The Jetpack plugin has different release cadences depending on the platform:
If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack. |
There was a problem hiding this comment.
Pull request overview
This pull request aims to fix a broken YouTube embed link issue by modifying how the YouTube shortcode filter is registered. The key change removes a conditional check that was previously used to determine when the filter should be hooked.
- Removes the conditional
jetpack_shortcodes_should_hook_pre_kses()check before adding thepre_ksesfilter - Adds a changelog entry documenting this bugfix
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| projects/plugins/jetpack/modules/shortcodes/youtube.php | Removes conditional wrapper and unconditionally registers the pre_kses filter for YouTube embed conversion |
| projects/plugins/jetpack/changelog/fix-youtube-embed-link | Adds changelog entry documenting the YouTube URL fix as a patch-level bugfix |
| Significance: patch | ||
| Type: bugfix | ||
|
|
||
| Shortcode: Fix broken Youtube URL |
There was a problem hiding this comment.
The word "Youtube" should be "YouTube" (with capital T and capital B) to match the official brand name and the naming convention used throughout the codebase.
| Shortcode: Fix broken Youtube URL | |
| Shortcode: Fix broken YouTube URL |
Code Coverage SummaryCoverage changed in 1 file.
|
05b8283 to
6ac741e
Compare
6ac741e to
e641934
Compare
Fixes #46409
Proposed changes:
wpcom_youtube_embed_crazy_url_initfor non-REST API requestsOther information:
Jetpack product discussion
Does this pull request change what data or activity we track or use?
Testing instructions: