45258 Commits

Author SHA1 Message Date
Sergey Biryukov
34d98887a2 Tests: Restore the original user role in the (add|remove)_user_role hooks test.
This makes sure the test does not unintentionally affect other tests.

Follow-up to [52823].

Fixes #54164.

git-svn-id: https://develop.svn.wordpress.org/trunk@52824 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-06 23:02:12 +00:00
Sergey Biryukov
864ab55b33 Users: Bring some consistency to user role hooks.
This standardizes the actions that one needs to hook to for tracking user role changes:

* `add_user_role` is only fired when the user has actually gained a new role.
* `remove_user_role` is only fired when the role was actually removed.

Both actions are now fired in `WP_User::set_role()` as appropriate.

Props dd32, SergeyBiryukov.
Fixes #54164.

git-svn-id: https://develop.svn.wordpress.org/trunk@52823 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-06 16:09:06 +00:00
Sergey Biryukov
f0fdad1c8e Query: Make sure WP_Query::get_queried_object() works for author_name before ::get_posts() is run.
Previously, the queried object with author data was not available before the posts loop when `author_name` is used in the query instead of `author`. With block themes, this use case appears to be more common to display the author name in the header.

This commit adjusts the logic in `WP_Query::get_queried_object()` to fall back to the `author_name` field if `author` is not present, similar to how taxonomy slugs are handled.

Follow-up to [1728], [3290], [10992].

Props dd32, swissspidy, SergeyBiryukov.
Fixes #55100.

git-svn-id: https://develop.svn.wordpress.org/trunk@52822 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-05 15:33:05 +00:00
Sergey Biryukov
73fdc6ada2 Docs: Add inline comments for non-visible characters in sanitize_title_with_dashes().
This aims to clarify the list of characters that are stripped from URLs or converted to a hyphen.

Follow-up to [51984].

See #47912, #54729.

git-svn-id: https://develop.svn.wordpress.org/trunk@52821 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-04 14:09:59 +00:00
Jb Audras
157d127fef Coding Standards: Improve formatting in /wp-admin/user-edit.php.
This change improves the formatting of `/wp-admin/user-edit.php` to avoid PHPCS failures when adding new code, which previously required new code to be indented multiple times, breaking alignment of the HTML parts. This change avoids disabling/enabling PHPCS for failing sniffs.

Props costdev, johnregan3, peterwilsoncc.
Fixes #54673.


git-svn-id: https://develop.svn.wordpress.org/trunk@52820 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-04 11:27:54 +00:00
Peter Wilson
567b2518f8 Themes: Hide block themes' live preview link following installation.
Prevent the Customizer/Live Preview button from showing for installed block themes when on the theme installation page.

Props antonvlasenko, costdev, ironprogrammer.
Fixes #54878.



git-svn-id: https://develop.svn.wordpress.org/trunk@52819 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-04 02:37:58 +00:00
David Baumwald
77561d0a30 Comments: Guard against potential PHP notices in get_comment_author and get_comment_ID.
In both `get_comment_author` and `get_comment_ID`, it's possible that these functions are called without a comment context.  Specifically, `get_comment_author` can be called without passing the `$comment_ID` parameter, and `get_comment_ID` relies on the `comment` global if there's no `$comment` parameter supplied.  This leads to a PHP notice of "Trying to get property of a non-object."

This change adds a check to both functions to ensure the `$comment->comment_ID` property is not empty before actually using its value.

Follow-up to [52223].

Props dd32.
Fixes #54379.

git-svn-id: https://develop.svn.wordpress.org/trunk@52818 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-03 20:32:20 +00:00
Sergey Biryukov
9defe855e6 Docs: Update the DocBlock for the wpmu_new_blog action to suggest wp_initialize_site as an alternative.
Follow-up to [43654], [52816].

See #49612.

git-svn-id: https://develop.svn.wordpress.org/trunk@52817 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-03 16:11:44 +00:00
Sergey Biryukov
3788002728 Networks and Sites: Suggest wp_initialize_site as an alternative for the deprecated wpmu_new_blog action.
The previously suggested alternative, `wp_insert_site`, does not get passed enough arguments and runs before the new site initialization routine is actually executed.

Follow-up to [43654].

Props asaquzzaman, henry.wright, MadtownLems.
Fixes #49612.

git-svn-id: https://develop.svn.wordpress.org/trunk@52816 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-03 15:56:07 +00:00
Sergey Biryukov
b28dcfd832 Docs: Add a @since note for WP::parse_request() about the new return value.
Includes minor code layout fixes for consistency. Additionally, this moves a more general unit test above the more specific one.

Follow-up to [52814].

See #10886.

git-svn-id: https://develop.svn.wordpress.org/trunk@52815 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-02 15:38:27 +00:00
Jonny Harris
69b9940da2 Bootstrap/Load: Stop unnecessary queries when using the do_parse_request filter.
Developers of plugins and themes can use the `do_parse_request` filter to hot-wire requests and hook in early to render custom pages. However, even through these request may not need post queries and 404 lookups to be run, they run anyway. This can results in unnecessary SQL queries running on these requests. By adding a return value to the `parse_request` method of the `WP` class, these queries can now be skipped. 

Props junsuijin, ryan, westi, sivel, dd32, wonderboymusic, arnee, tyxla, DrewAPicture, lukecavanagh, SergeyBiryukov, davidbaumwald, Spacedmonkey, pbearne.
Fixes #10886.



git-svn-id: https://develop.svn.wordpress.org/trunk@52814 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-02 15:10:48 +00:00
Sergey Biryukov
99fd93c7df Administration: Require a valid action parameter to be set for admin-ajax.php requests.
This avoids `Array to string conversion` PHP notices when an array is passed as the `action` parameter.

Additionally, send an appropriate HTTP response status code when an invalid action is passed to `admin-post.php`.

Follow-up to [13175], [19738], [41120], [41926].

Props dd32.
Fixes #55212.

git-svn-id: https://develop.svn.wordpress.org/trunk@52813 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-02 14:58:09 +00:00
Sergey Biryukov
f0dfa682a5 Themes: Make sure the current_theme_supports-{$feature} filter is consistently applied.
Previously, the filter was not applied if there are no arguments passed to `current_theme_supports()`.

Follow-up to [12350], [19682].

Props helgatheviking, azouamauriac, pavanpatil1, SergeyBiryukov.
Fixes #55219.

git-svn-id: https://develop.svn.wordpress.org/trunk@52812 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-01 16:05:14 +00:00
Sergey Biryukov
44122bf7df External Libraries: Upgrade PHPMailer to version 6.6.0.
This is a minor feature release.

> Prior to this version, any OAuth provider needed to extend the provided `OAuth` base class, and this made it difficult to use with libraries other than ones based on the default [https://github.com/thephpleague/oauth2-client league] client packages. The OAuth property now accepts anything that implements the `OAuthProviderInterface`, making it much easier to use things like [https://github.com/googleapis/google-api-php-client Google's own OAuth classes]. Existing implementations that extend the provided `OAuth` base class will still work, as that base class now implements this interface too.
>
> When TLS errors occurred in PHPMailer, the error messages were often missing important info that might help diagnose/solve the problem. These error messages should now be more informative. A minor change is that a TLS error on SMTP connect will now throw an exception if exceptions are enabled.

Release notes:
https://github.com/PHPMailer/PHPMailer/releases/tag/v6.6.0

For a full list of changes in this update, see the PHPMailer GitHub:
https://github.com/PHPMailer/PHPMailer/compare/v6.5.4...v6.6.0

Follow-up to [50628], [50799], [51169], [51634], [51635], [52252], [52749].

Props jrf, Synchro, miken32.
Fixes #55277.

git-svn-id: https://develop.svn.wordpress.org/trunk@52811 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-28 21:36:22 +00:00
Sergey Biryukov
90bc0edaef Docs: Use third-person singular verbs for function descriptions in wp-includes/formatting.php, per the documentation standards.
See #54729.

git-svn-id: https://develop.svn.wordpress.org/trunk@52810 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-28 16:01:47 +00:00
Sergey Biryukov
2d5f6833fb I18N: Add a $locale parameter for remove_accents().
This highlights the fact that `remove_accents()` is locale-aware and makes it easier to utilize the function with different locales without having to use `switch_to_locale()` or the `locale` filter.

Additionally, this commit relaxes the check for character replacements in German locales to include formal and informal variants of any `de_*` locale, even if WordPress does not have a native translation for some of them yet.

Props malthert, johnbillion, knutsp, ocean90, SergeyBiryukov.
Fixes #54415.

git-svn-id: https://develop.svn.wordpress.org/trunk@52809 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-28 15:40:15 +00:00
Jb Audras
d241c8ccea Administration: Consistency fixes on keyboard shortcuts instructions.
This changeset capitalizes the letter of keyboard shortcuts and replaces `CTRL` with `Ctrl`, for better consistency.

Props Presskopp, sabernhardt, joyously, SergeyBiryukov, audrasjb.
Fixes #40582.


git-svn-id: https://develop.svn.wordpress.org/trunk@52808 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-27 22:47:19 +00:00
Sergey Biryukov
33048b9333 Filesystem API: Include the ssh-ed25519 public key signature algorithm as an alternative to ssh-rsa.
The `ssh-rsa` signature algorithm is disabled by default as of OpenSSH 8.8, which breaks SSH2 uploads in WordPress on modern systems. `ssh-ed25519` is one of the suggested alternatives, supported since OpenSSH 6.5.

References:
* [https://www.openssh.com/txt/release-8.2 OpenSSH 8.2 release notes]
* [https://www.openssh.com/txt/release-8.7 OpenSSH 8.7 release notes]
* [https://www.openssh.com/txt/release-8.8 OpenSSH 8.8 release notes]

Follow-up to [8865].

Props richybkreckel, dd32.
Fixes #52409.

git-svn-id: https://develop.svn.wordpress.org/trunk@52807 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-27 15:00:58 +00:00
Joe Dolson
5445ae3ce0 Media: Use consistent mirroring check in media views.
Change the mirroring property verification method to be consistent with other usages across models and attachments, since we don't care whether it's assigned directly on inherited.

Props MMDeveloper, SergeyBiryukov.
Fixes #53856.


git-svn-id: https://develop.svn.wordpress.org/trunk@52806 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-27 00:54:57 +00:00
Sergey Biryukov
69a4f35a7b Query: Correct the "matched rule" condition in WP::parse_request().
The `WP::$matched_rule` property is always set now, so we should check that it's not empty instead.

Follow-up to [52804].

See #55222.

git-svn-id: https://develop.svn.wordpress.org/trunk@52805 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-26 14:32:37 +00:00
Sergey Biryukov
e537f7cddf Query: Preinitialize the WP class properties to their default values.
This avoids an `array_keys() expects parameter 1 to be array, null given` PHP warning for the `query_vars` property in `WP::build_query_string()` when disabling request parsing via the `do_parse_request` filter.

Props dd32, SergeyBiryukov.
Fixes #55222.

git-svn-id: https://develop.svn.wordpress.org/trunk@52804 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-26 14:26:21 +00:00
Jb Audras
b00eda0e0f Themes: Remove the Live Preview link when installing a block theme from a zip archive.
This changeset removes the Live Preview link for block-based themes when installing for a zip archive, since the customizer is disabled by default for block themes.

Follow-up to [52353].

Props alanjacobmathew, hellofromTonya, antonvlasenko, ironprogrammer.
Fixes #54578.


git-svn-id: https://develop.svn.wordpress.org/trunk@52802 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-26 08:14:22 +00:00
Jb Audras
d551051982 Administration: Further enhancements on small text fields after [52649].
This changeset replaces `#mailserver_port` to a more generic selector, fixes a coding standard issue, and adds a bigger margin to the field.

Follow-up to [52649].

Props SergeyBiryukov, kebbet, pyrobd.
Fixes #50177.


git-svn-id: https://develop.svn.wordpress.org/trunk@52801 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-25 15:47:37 +00:00
Sergey Biryukov
0bc5d361c3 Tests: Rename the $success variable to $result in the wp_mail() test for an empty home URL.
The previously name could be a bit confusing if the function is expected to fail.

Follow-up to [52799].

See #54730.

git-svn-id: https://develop.svn.wordpress.org/trunk@52800 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-25 14:08:53 +00:00
Sergey Biryukov
391922e8b4 Code Modernization: Check the return type of wp_parse_url() in wp_mail().
As per the PHP manual:
> If the `component` parameter is omitted, an associative array is returned.
> If the `component` parameter is specified, `parse_url()` returns a string (or an int, in the case of `PHP_URL_PORT`) instead of an array. If the requested component doesn't exist within the given URL, `null` will be returned.

Reference: [https://www.php.net/manual/en/function.parse-url.php#refsect1-function.parse-url-returnvalues PHP Manual: parse_url(): Return Values]

In PHP 8.1, if the home URL does not have a "host" component, it would lead to a `substr(): Passing null to parameter #1 ($string) of type string is deprecated` notice.

Changing the logic around and adding validation for the return type value of `wp_parse_url()` prevents that.

Follow-up to [48601], [51606], [51622], [51626], [51629], [51630].

Props dennisatyoast, jrf.
See #54730.

git-svn-id: https://develop.svn.wordpress.org/trunk@52799 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-25 13:46:23 +00:00
Sergey Biryukov
06b740f5f6 Tests: Add a @ticket reference for the current_theme_supports-{$feature} filter test.
Follow-up to [19682], [495/tests].

Props azouamauriac.
See #54725.

git-svn-id: https://develop.svn.wordpress.org/trunk@52798 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-25 13:07:25 +00:00
Jb Audras
ee201606fb Media: Make get_post_galleries() only return galleries.
This change makes sure only gallery content is returned by `get_post_galleries()`. It fixes an issue where non gallery block content was also returned by the function.

Props BinaryMoon, costdev, glendaviesnz.
Fixes #55203.


git-svn-id: https://develop.svn.wordpress.org/trunk@52797 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-25 12:42:10 +00:00
Jonny Harris
f4addf3ff5 REST API: Pass WP_REST_Request object to the rest_index filter.
Props johnregan3, TimothyBlynJacobs, Spacedmonkey, hasanuzzamanshamim.
Fixes #48638. 


git-svn-id: https://develop.svn.wordpress.org/trunk@52796 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-24 22:34:56 +00:00
Jb Audras
16cd22183d Docs: Correct return type for get_post_custom().
Props chouby, audrasjb.
Fixes #55249.
See #54729.


git-svn-id: https://develop.svn.wordpress.org/trunk@52795 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-24 21:24:41 +00:00
Sergey Biryukov
33f3f1bbfd Docs: Add missing descriptions for some parameters of WP_Walker::paged_walk().
Props bhrugesh12.
Fixes #55225.

git-svn-id: https://develop.svn.wordpress.org/trunk@52794 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-24 13:31:58 +00:00
Jb Audras
44e308c12e Docs: Correct return type for get_block_metadata_i18n_schema().
Props jeremyfelt.
Fixes #55243.
See #54729.


git-svn-id: https://develop.svn.wordpress.org/trunk@52793 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-24 08:25:25 +00:00
Joe Dolson
dec3f13bac Media: Stop arrow keys switching media if URL focused.
Keyboard handlers were prevented from navigating attachments in input fields, but the key handler excluded readonly fields, like the media URL field. This could prevent exploring the URL using the keyboard.

Props jrivett, joemcgill, afercia.
Fixes #43202.


git-svn-id: https://develop.svn.wordpress.org/trunk@52792 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-24 04:33:47 +00:00
Jb Audras
44ec790fe6 Themes: Avoid undefined variable warning on get_svg_filters().
This change fixes an undefined variable warning thrown when `duotone` color setting was set to null` in Block Themes `theme.json` file.

Follow-up to [52768].

Props aliakseyenkaihar, audrasjb, rafiahmedd.
Fixes #55241.


git-svn-id: https://develop.svn.wordpress.org/trunk@52791 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-23 23:15:56 +00:00
Jb Audras
75e10b1447 Plugins: Add focus style to plugin icon link in plugin cards.
This change adds a blue focus outline to the icon on plugin cards, for consistency with the text part of the link.

Props hitendra-chopda, SergeyBiryukov, afercia, themattroyal, imokol, sabernhardt, audrasjb.
Fixes #45209.


git-svn-id: https://develop.svn.wordpress.org/trunk@52790 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-23 21:18:49 +00:00
Tonya Mork
6853d10368 Formatting: Make terms in wpautop() and shortcode_unautop() more welcoming and inclusive.
The developer facing humor in these functions were from a different era of WordPress. Tolerance for in-jokes and other developer facing humor has decreased over the years. Terms like "pee" and "tinkle" may make some folks chuckle while for others it makes them uncomfortable.

Terminology of the past is being (or has been) re-evaluated to transform words into a language that are inclusive and welcome for all. This commit is part of that effort as it replaces.

Follow-up [13], [9255].

Props ricomoorman, tzipporahwitty, ironprogrammer, peterwilsoncc, jeremyfelt, Viper007Bond, rmccue, SergeyBiryukov, hellofromTonya.
Fixes #25615.

git-svn-id: https://develop.svn.wordpress.org/trunk@52789 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-23 20:01:55 +00:00
Jb Audras
1940ae449f Help/About: Revert [52783].
Point releases about page changelog should not be committed to trunk. This changeset reverts [52783].

Unprops audrasjb.


git-svn-id: https://develop.svn.wordpress.org/trunk@52784 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-22 10:59:16 +00:00
Jb Audras
456dfd6b76 Help/About: Update the About page for WordPress 5.9.1.
Props hellofromTonya, audrasjb.
Fixes #55173.


git-svn-id: https://develop.svn.wordpress.org/trunk@52783 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-22 10:31:27 +00:00
Jb Audras
8a10a48789 Twenty Twenty-Two: Bump theme version to 1.1.
This change bumps the version of the Twenty Twenty-Two bundled theme in preparation for release with WordPress 5.9.1.

Props peterwilsoncc, petaryoast, audrasjb, SergeyBiryukov, rafiahmedd.
Fixes #55056.


git-svn-id: https://develop.svn.wordpress.org/trunk@52781 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-21 20:53:15 +00:00
Sergey Biryukov
7a96aefac6 Docs: Use third-person singular verbs in some test descriptions in phpunit/tests/functions/.
Follow-up to [42971], [45371], [46159], [46175], [47779], [50962], [50964], [51910], [52778].

Props azouamauriac, SergeyBiryukov.
See #54725.

git-svn-id: https://develop.svn.wordpress.org/trunk@52780 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-21 14:50:07 +00:00
Sergey Biryukov
f764d7381a Docs: Fix typo in TracTickets::isTracTicketClosed() description.
Follow-up to [761/tests], [762/tests], [891/tests].

See #54729.

git-svn-id: https://develop.svn.wordpress.org/trunk@52779 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-20 10:12:37 +00:00
Sergey Biryukov
109953c1fb Tests: Convert _wp_to_kebab_case() tests to use a data provider.
Follow-up to [51198], [51225].

See #54725.

git-svn-id: https://develop.svn.wordpress.org/trunk@52778 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-19 13:43:53 +00:00
Sergey Biryukov
3d0607f0df Docs: Correct parameter types for data_wp_validate_boolean().
Follow-up to [46159], [46224], [52775], [52776].

See #54725, #54729.

git-svn-id: https://develop.svn.wordpress.org/trunk@52777 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-19 13:25:05 +00:00
Sergey Biryukov
2836ece22f Docs: Improve some DocBlocks in wp_validate_boolean() tests for consistency.
Follow-up to [46159], [46224], [52775].

See #54725, #54729.

git-svn-id: https://develop.svn.wordpress.org/trunk@52776 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-19 13:00:04 +00:00
Sergey Biryukov
d0f8d4ff70 Tests: Correct the order of expected and actual values in wp_validate_boolean() tests.
This corrects the order of the parameters when used in assertions so if/when they fail the failure message is correct.

Additionally, this commit moves the test function before the data provider, for consistency with other tests.

Follow-up to [46159], [46224].

See #54725.

git-svn-id: https://develop.svn.wordpress.org/trunk@52775 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-19 12:40:48 +00:00
Sergey Biryukov
407325eb1a Tests: Correct the order of expected and actual values in wp_array_slice_assoc() tests.
This corrects the order of the parameters when used in assertions so if/when they fail the failure message is correct.

Follow-up to [45371].

See #54725.

git-svn-id: https://develop.svn.wordpress.org/trunk@52774 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-19 12:37:05 +00:00
Sergey Biryukov
cff706c8f0 Tests: Correct the order of expected and actual values in get_status_header_desc() tests.
This corrects the order of the parameters when used in assertions so if/when they fail the failure message is correct.

Follow-up to [46107].

See #54725.

git-svn-id: https://develop.svn.wordpress.org/trunk@52773 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-19 12:36:04 +00:00
Jonny Harris
c98f4c04db Cache API: Add wp_cache_flush_runtime function
Add a new function called `wp_cache_flush_runtime` to existing caching functions found in WordPress. This function allows users to flush the runtime (in-memory) cache, without flushing the entire persistent cache. 

Props: Spacedmonkey, tillkruess, flixos90, adamsilverstein, SergeyBiryukov, barryhughes. 
Fixes: #55080.



git-svn-id: https://develop.svn.wordpress.org/trunk@52772 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-18 12:04:52 +00:00
Tonya Mork
a3cbbc419d Editor: Automatically apply global styles duotone filters to render in post editor.
Global styles duotone filters were not rendering in the post editor. This fixes that by adding `wp_global_styles_render_svg_filters` to the `in_admin_header` so it renders in the body before the editor.

Follow-up [52757].

Props ajlende, abhanonstopnewsuk.
Fixes #55190.

git-svn-id: https://develop.svn.wordpress.org/trunk@52768 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-17 20:43:39 +00:00
Jb Audras
5c845102ac Editor: Update block editor packages for WordPress 5.9.1.
The following packages were updated:

- @wordpress/block-directory@3.0.27
- @wordpress/block-editor@8.0.17
- @wordpress/block-library@6.0.26
- @wordpress/components@19.2.3
- @wordpress/core-data@4.0.10
- @wordpress/customize-widgets@2.0.27
- @wordpress/e2e-tests@2.5.18
- @wordpress/edit-post@5.0.27
- @wordpress/edit-site@3.0.27
- @wordpress/edit-widgets@3.1.22
- @wordpress/editor@12.0.21
- @wordpress/format-library@3.0.23
- @wordpress/interface@4.1.18
- @wordpress/list-reusable-blocks@3.0.20
- @wordpress/nux@5.0.20
- @wordpress/reusable-blocks@3.0.23
- @wordpress/server-side-render@3.0.20
- @wordpress/widgets@2.0.23

Props Mamaduka.
See #55179.


git-svn-id: https://develop.svn.wordpress.org/trunk@52765 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-17 19:16:57 +00:00
Tonya Mork
4f18e39896 Editor: Adds an additional check to guard against incompete presets.
Adds an additional guard to ensure the value of `$preset_metadata['value_key']` actually exists as a key in the `$preset` array. Fixes `Warning: Undefined array key` error. 

Intentionally adds the check into the existing `isset()` as it's native to PHP, more efficient, and a good pattern.

Follow-up [52049].

Props jeherve, swissspidy, sergeybiryukov, jrf.
Fixes #55161.



git-svn-id: https://develop.svn.wordpress.org/trunk@52763 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-17 18:45:35 +00:00