Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#58494 http freq #45

Open
wants to merge 106 commits into
base: ticket/58494
Choose a base branch
from

Conversation

MichaelSalp
Copy link

Hey Adam, my first try to create a pull request for https://core.trac.wordpress.org/ticket/58494 into your fork.

johnbillion and others added 30 commits August 28, 2023 21:51
…l data export and erasure.

See #58833


git-svn-id: https://develop.svn.wordpress.org/trunk@56482 602fd350-edb4-49c9-b593-d223f7449a82
This is a minor maintenance release.

Note: WordPress core does not include PHPMailer's DSN class, as it is not particularly relevant for WP.

References:
* [https://github.com/PHPMailer/PHPMailer/releases/tag/v6.8.1 PHPMailer 6.8.1 release notes]
* [PHPMailer/PHPMailer@v6.8.0...v6.8.1 Full list of changes in PHPMailer 6.8.1]

Follow-up to [50628], [50799], [51169], [51634], [51635], [52252], [52749], [52811], [53500], [53535], [53917], [54427], [54937], [55557].

Props jrf, Synchro.
Fixes #59238.

git-svn-id: https://develop.svn.wordpress.org/trunk@56484 602fd350-edb4-49c9-b593-d223f7449a82
…butes.

Props maltfield, aslamdoctor.
Fixes #59206.

git-svn-id: https://develop.svn.wordpress.org/trunk@56488 602fd350-edb4-49c9-b593-d223f7449a82
Updates the calls to permission validation calls for the `directory-sizes` and `page-cache` routes to actually match the route names.

Follow-up to r54043 and r49154.

Props szepeviktor.
Fixes #59236

git-svn-id: https://develop.svn.wordpress.org/trunk@56489 602fd350-edb4-49c9-b593-d223f7449a82
This fixes an issue introduced in [55569] that broke sort ordering by `post_modified_gmt` or `modified_gmt`.

Props david.binda, azaozz, spacedmonkey, flixos90, joemcgill.
Fixes #59226.


git-svn-id: https://develop.svn.wordpress.org/trunk@56490 602fd350-edb4-49c9-b593-d223f7449a82
This avoids an additional query by passing the query args directly to the `WP_Query::query()` method, rather than to the constructor and calling get_posts(), following [55569].

Props david.binda, azaozz, spacedmonkey, mukesh27, flixos90, SergeyBiryukov, joemcgill.
Fixes #59224.


git-svn-id: https://develop.svn.wordpress.org/trunk@56491 602fd350-edb4-49c9-b593-d223f7449a82
…operties.

The single parameter signature, which was used for setting the value on a static property, is deprecated since PHP 8.3. A cross-version solution is to pass `null` as the first parameter.

This commit updates all the instances that use the deprecated signature in WordPress core.

Reference: [https://wiki.php.net/rfc/deprecate_functions_with_overloaded_signatures#reflectionpropertysetvalue PHP RFC: Deprecate functions with overloaded signatures: ReflectionProperty::setValue()].

Follow-up to [53152], [54493], [54799].

Props jrf, costdev, Tests: Correct uses of `ReflectionProperty::setValue()` for static properties.

The single parameter signature, which was used for setting the value on a static property, is deprecated since PHP 8.3. A cross-version solution is to pass `null` as the first parameter.

This commit updates all the instances that use the deprecated signature in WordPress core.

Reference: [https://wiki.php.net/rfc/deprecate_functions_with_overloaded_signatures#reflectionpropertysetvalue PHP RFC: Deprecate functions with overloaded signatures: ReflectionProperty::setValue()].

Follow-up to [53152], [54493], [54799].

Props jrf, costdev, sc0ttkclark.
See #59231.

git-svn-id: https://develop.svn.wordpress.org/trunk@56492 602fd350-edb4-49c9-b593-d223f7449a82
It was a design goal of the HTML Processor to abort processing its input document when encountering unsupported markup. Unfortunately there was no test for this and so-far, the HTML Processor has paused, but continued processing in these situations.

In this patch a new test ensures that the HTML Processor stops and refuses to move forward after encountering any unsupported markup. It also ensures that it doesn't report any current tag names since unsupported markup could imply that the read tag name is different than the parsed tag name.

Props dmsnell.
Fixes #59167.

git-svn-id: https://develop.svn.wordpress.org/trunk@56493 602fd350-edb4-49c9-b593-d223f7449a82
…()`.

This aims to improve performance by calling `sanitize_url()` directly, instead of the `esc_url_raw()` wrapper. As of WordPress 6.1, `sanitize_url()` is the recommended function for sanitizing a URL for database or redirect usage.

This replaces the two remaining instances of `esc_url_raw()` with `sanitize_url()` in WordPress core.

Follow-up to [53455], [53933], [54522].

Props rajinsharwar, SergeyBiryukov.
Fixes #59247.

git-svn-id: https://develop.svn.wordpress.org/trunk@56494 602fd350-edb4-49c9-b593-d223f7449a82
This changeset prevents a PHP 8.3 deprecation shown when enabling debug and calling `get_class()` without arguments.

For more info about this deprecation, see https://wiki.php.net/rfc/deprecate_functions_with_overloaded_signatures#get_class_and_get_parent_class.

Props ipajen, rajinsharwar, SergeyBiryukov, jrf.
Fixes #58876.





git-svn-id: https://develop.svn.wordpress.org/trunk@56495 602fd350-edb4-49c9-b593-d223f7449a82
…put.

This changeset updates `wp_default_packages_inline_scripts()` to add relative time strings to the `wp-date` inline script, so the JS version of `human_time_diff` 
can output translated strings.

Props ramonopoly, oandregal, swissspidy, manzoorwanijk, adrianduffell, Presskopp.
Fixes #59219, #47373.





git-svn-id: https://develop.svn.wordpress.org/trunk@56496 602fd350-edb4-49c9-b593-d223f7449a82
This changeset adds an exception to prevent permission issues on `.docx` generated by Google Docs. This is a temporary fix for an upstream bug on the `finfo_file()` 
PHP function which returns a redundant MIME type for these documents.

Props winterstreet, jakariaistauk, mujuonly, mi5t4n, annashopina, audrasjb, azaozz, mikeschroder, oglekler.
Fixes #57898.





git-svn-id: https://develop.svn.wordpress.org/trunk@56497 602fd350-edb4-49c9-b593-d223f7449a82
PHP 8.3 is expected to be released at the end of November 2023.

Enabling the tests to run in CI on PHP 8.3 allows WordPress core to start getting ready.

Note: Xdebug-related tests will not be run on PHP 8.3 at this time as the Docker image for PHP 8.3 does not contain Xdebug yet. Once a stable release of Xdebug 3.3.0 is available, it can be added to the Docker image and the test step can then be enabled for PHP 8.3.

Follow-up to [53922], [56492], [56495].

Props jrf, costdev.
See #59231.

git-svn-id: https://develop.svn.wordpress.org/trunk@56498 602fd350-edb4-49c9-b593-d223f7449a82
…n/includes/` files.

Props upadalavipul.
Fixes #59254.





git-svn-id: https://develop.svn.wordpress.org/trunk@56499 602fd350-edb4-49c9-b593-d223f7449a82
Introducing Font Face, a server-side `@font-face` styles generator and printer. 

tl;dr:
* Introduces Font Face.
* Deprecates `_wp_theme_json_webfonts_handler()`.

**Introduce Font Face**

From an array of fonts (i.e. each font-family and its font variations to be processed), it:

1. Validates each `font-face` declaration, i.e. the CSS property and value pairing. If validation fails, processing stops with no font-face styles printed.
3. Generates the `@font-face` CSS for each font-family.
4. Prints the CSS within a `<style id="wp-fonts-local">` element.

The entry point into Font Face is through a new global function called `wp_print_font_faces()`, which is automatically called:

* when the `'wp_head'` hook runs (for the front-end).
* when the `'admin_print_styles'` hook runs (for the back-end).
* when `_wp_get_iframed_editor_assets()` runs to inject the `@font-face` styles into the iframed editor.

Once called, it gets the fonts from Theme_JSON merged data layer, which includes theme defined fonts and user activated fonts (once the Font Library #59166 is introduced into Core).

For classic sites, themes and plugins can directly call `wp_print_font_faces()` and pass their fonts array to it for processing.

**Deprecates `_wp_theme_json_webfonts_handler()`.**

As Font Face is a direct replacement, the stopgap code in `_wp_theme_json_webfonts_handler()` (introduced in 6.0.0 via [53282]) is deprecated and unused in Core.

**Props note:**
There's a long multiple year history baked into Font Face, which dates back to the early versions of a web font API (see #46370 and [WordPress/gutenberg#41479 roadmap]. The props list includes those who contributed from those early versions up to this commit.

**References:**
* #46370 original (Web)Fonts API proposal for registering and enqueuing web fonts.
* [WordPress/gutenberg#41479 Gutenberg tracking issue] which includes the evolution from Webfonts API to Fonts API to Font Face.
* [53282] / #55567 Added the stopgap code `_wp_theme_json_webfonts_handler()` in 6.0.
* [https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face @font-face on mdn web docs]
* #59166 Font Library: Font manager for WordPress

Follow-up to [53282].

Props aristath, jonoaldersonwp, hellofromTonya, andraganescu, annezazu, antonvlasenko, arena, askdesign, azaozz, bph, bradley2083, colorful-tones, costdev, davidbaumwald, desrosj, dingo_d, djcowan, domainsupport, dryanpress, elmastudio, flixos90, francina, garrett-eclipse, gigitux, grantmkin, grapplerulrich, gziolo, ironprogrammer, jb510, jeffpaul, jeremyyip, jffng, joostdevalk, jorgefilipecosta, juanmaguitar, mamaduka, matveb, mburridge, mitogh, ndiego, ntsekouras, oandregal, ocean90, oglekler, paaljoachim, pagelab, peterwilsoncc, poena, priethor, scruffian, SergeyBiryukov, shiloey, simison, skorasaurus, soean, westonruter, wildworks, zaguiini.
Fixes #59165.

git-svn-id: https://develop.svn.wordpress.org/trunk@56500 602fd350-edb4-49c9-b593-d223f7449a82
Removes the test file and `webfonts` directory for the stopgap code that was deprecated by [56500].

Follow-up to [56500], [53282].

Fixes #59165.

git-svn-id: https://develop.svn.wordpress.org/trunk@56501 602fd350-edb4-49c9-b593-d223f7449a82
Adds the ability to process block style variations to the `remove_insecure_properties` function of theme json class.

Props dsas, ramonopoly.
Fixes #59108.


git-svn-id: https://develop.svn.wordpress.org/trunk@56502 602fd350-edb4-49c9-b593-d223f7449a82
Changes fluid typography calculation to use fallback value if layout wide size is a fluid value.

Props ramonopoly, mukesh27, jastos, aurooba.
See #58754.


git-svn-id: https://develop.svn.wordpress.org/trunk@56503 602fd350-edb4-49c9-b593-d223f7449a82
…d_form()`.

Follow-up to [27316].

Props upadalavipul.
See #59254.

git-svn-id: https://develop.svn.wordpress.org/trunk@56504 602fd350-edb4-49c9-b593-d223f7449a82
Follow-up to [49638].

Props upadalavipul.
See #59254.

git-svn-id: https://develop.svn.wordpress.org/trunk@56505 602fd350-edb4-49c9-b593-d223f7449a82
This extends the performance test workflow added in [55459] to also run tests against the target branch (if running on a pull request) or the previous commit (if running on trunk).

Those results are then compared with the ones from the current commit, and the difference is displayed as a GitHub Actions workflow summary for convenience.

Props mukesh27, flixos90, desrosj, joemcgill, swissspidy.
Fixes #58358, #58359.
See #56150.

git-svn-id: https://develop.svn.wordpress.org/trunk@56506 602fd350-edb4-49c9-b593-d223f7449a82
…ck themes.

Block themes currently lack the means to trigger the main query loop for singular content, since they cannot reasonably use the `core/query` and `core/post-template` blocks which are intended only for displaying a list of posts. So far, the missing main query loop on singular block templates has been worked around by enforcing the loop in certain `core/post-*` blocks, which however causes other bugs.

This changeset ensures that the main query loop is still started for singular block theme templates, by wrapping the entire template into the loop, which will by definition only have a single cycle as it only encompasses a single post. This is currently the most reliable solution, since even if there were blocks to properly trigger the main query loop on singular content, it would be unrealistic to expect all existing block themes to update their templates accordingly. It may be revisited in the future.

Props gziolo, youknowriad, joemcgill, costdev, mukesh27, flixos90.
Fixes #58154.
See #59225, #58027.


git-svn-id: https://develop.svn.wordpress.org/trunk@56507 602fd350-edb4-49c9-b593-d223f7449a82
This function accepts an associative array of option names and their autoload values to set, and it will update those values in the database in bulk, only for those options where the autoload field is not already set to the given value.

Two wrapper functions for ease of use accompany the new main function:
* `wp_set_options_autoload( $options, $autoload )` can be used to set multiple options to the same autoload value.
* `wp_set_option_autoload( $option, $autoload )` can be used to set the autoload value for a single option.

All of these functions allow changing the autoload value of an option, which previously has only been possible in combination with updating the value. This limitation prevented some relevant use-cases: For example, a plugin deactivation hook could set all of its options to not autoload, as a cleanup routine, while not actually deleting any data. The plugin's activation hook could then implement the reverse, resetting those options' autoload values to the originally intended ones for when using the plugin.

Props boonebgorges, joemcgill, costdev, mukesh27, SergeyBiryukov, tabrisrp, flixos90.
Fixes #58964.


git-svn-id: https://develop.svn.wordpress.org/trunk@56508 602fd350-edb4-49c9-b593-d223f7449a82
Follow-up to [48535].

Props Michi91, Presskopp.
Fixes #58737.

git-svn-id: https://develop.svn.wordpress.org/trunk@56509 602fd350-edb4-49c9-b593-d223f7449a82
…ogle Docs.

This expands the code block previously added for `.docx` files to include `.xlsx` files as well, which are known to have the same issue with `finfo_file()`.

Includes a unit test case for `wp_check_filetype_and_ext()`.

Reference: [https://bugs.php.net/bug.php?id=77784 PHP Bug #77784: mime_content_type() result gets doubled for .xlsx].

Follow-up to [56497].

See #57898.

git-svn-id: https://develop.svn.wordpress.org/trunk@56510 602fd350-edb4-49c9-b593-d223f7449a82
….php`.

Follow-up to [4955], [38571].

Props aristath, poena, afercia, SergeyBiryukov.
See #58831.

git-svn-id: https://develop.svn.wordpress.org/trunk@56511 602fd350-edb4-49c9-b593-d223f7449a82
…_Gallery class.

In the method `WP_Widget_Media_Gallery::has_content` call `_prime_post_caches` before the foreach loop. This ensures that the post objects are primed in memory before trying to access the post object in `get_post_type`.

Props niravsherasiya7707, spacedmonkey, mukesh27.
Fixes #58757.

git-svn-id: https://develop.svn.wordpress.org/trunk@56512 602fd350-edb4-49c9-b593-d223f7449a82
…enabled.

Prior to this commit, the `WP_Query` class split the query for posts into two database queries. First, it initiated an ID-based query to retrieve post IDs, followed by a call to _prime_post_caches to fetch post objects if they weren't already in memory. This splitting of queries was limited to cases where fewer than 500 posts were being requested, to prevent a potentially large database query within the IN statement in _prime_post_caches.

However, this limitation becomes unnecessary when a persistent object cache is enabled, as the post objects can be efficiently retrieved from the fast object cache. This commit transfers the responsibility of fetching posts to the object cache, which not only speeds up the process but also reduces the strain on the database server.

Props peterwilsoncc, spacedmonkey, SergeyBiryukov.
Fixes #57296.

git-svn-id: https://develop.svn.wordpress.org/trunk@56513 602fd350-edb4-49c9-b593-d223f7449a82
…wp-includes/functions.php`.

While using reserved PHP keywords as parameter name labels is allowed, in the context of function calls using named parameters in PHP 8.0+, this will easily lead to confusion. To avoid that, it is recommended not to use reserved keywords as function parameter names.

This commit renames the `$class` parameter to `$class_name` in `_deprecated_class()`.

Follow-up to [54929], [56467].

Props jrf.
See #59161.

git-svn-id: https://develop.svn.wordpress.org/trunk@56514 602fd350-edb4-49c9-b593-d223f7449a82
Consistently expand `Add New` links to include the type of content to add. Improve consistency of text casing to use initial caps throughout.

Props afercia, gonzomir, alexstine, swissspidy, joedolson.
Fixes #47125.

git-svn-id: https://develop.svn.wordpress.org/trunk@56515 602fd350-edb4-49c9-b593-d223f7449a82
felixarntz and others added 28 commits September 13, 2023 20:50
…ion signature.

Since most core scripts are registered using `WP_Scripts::add()`, which is not affected by the signature change, only calls to `wp_register_script()` using the old signature need to be updated. There is only a single instance left, which is updated in this changeset.

Props incursadesigns.
Fixes #58634.


git-svn-id: https://develop.svn.wordpress.org/trunk@56568 602fd350-edb4-49c9-b593-d223f7449a82
…r WP<6.3.

Amends [56556].
Props westonruter, flixos90, peterwilsoncc.
Fixes #59316.


git-svn-id: https://develop.svn.wordpress.org/trunk@56569 602fd350-edb4-49c9-b593-d223f7449a82
Add usages of `wp_admin_notice()` and `wp_get_admin_notice()` on `.notice-[type]` in the root level of `/wp-admin/`. Ongoing task to implement new function across core.

Props costdev, joedolson.
See #57791.

git-svn-id: https://develop.svn.wordpress.org/trunk@56570 602fd350-edb4-49c9-b593-d223f7449a82
Add usages of `wp_admin_notice()` and `wp_get_admin_notice()` on `.notice-[type]` in the root level of `/wp-admin/includes`. Ongoing task to implement new function across core.

Props costdev, joedolson.
See #57791.

git-svn-id: https://develop.svn.wordpress.org/trunk@56571 602fd350-edb4-49c9-b593-d223f7449a82
Add usages of `wp_admin_notice()` and `wp_get_admin_notice()` on `.notice-[type]` in the root level of `/wp-includes/`. Ongoing task to implement new function across core.

Props costdev, joedolson.
See #57791.

git-svn-id: https://develop.svn.wordpress.org/trunk@56572 602fd350-edb4-49c9-b593-d223f7449a82
Add usages of `wp_admin_notice()` and `wp_get_admin_notice()` on `.updated` in the root level of `/wp-admin/`. Ongoing task to implement new function across core.

Props costdev, joedolson.
See #57791.

git-svn-id: https://develop.svn.wordpress.org/trunk@56573 602fd350-edb4-49c9-b593-d223f7449a82
Stops style engine from combining CSS selectors by default so that rule order is preserved.

Props ramonopoly, rajinsharwar, timdix, costdev, audrasjb, SergeyBiryukov, JeffPaul, mukesh27.
Fixes #58811.


git-svn-id: https://develop.svn.wordpress.org/trunk@56574 602fd350-edb4-49c9-b593-d223f7449a82
Removes redundant local variable and changes validate_custom_css() access modifier from private to protected.

Props ramonopoly, spacedmonkey.
Fixes #59296.



git-svn-id: https://develop.svn.wordpress.org/trunk@56575 602fd350-edb4-49c9-b593-d223f7449a82
In [56573], a typo caused `wp_admin()` to be called rather than `wp_admin_notice()`.

This fixes the typo to correctly call `wp_admin_notice()`.

Follow-up to [56573].

Props takayukister.
See #57791.

git-svn-id: https://develop.svn.wordpress.org/trunk@56576 602fd350-edb4-49c9-b593-d223f7449a82
Adds `delete_posts` to capabilities for the `wp_block` post type.

Props ramonopoly, johnbillion, dhruvishah2203, audrasjb.
Fixes #59041.


git-svn-id: https://develop.svn.wordpress.org/trunk@56577 602fd350-edb4-49c9-b593-d223f7449a82
Rather than using `_inject_theme_attribute_in_block_template_content` to inject the `theme` attribute into all Template Part blocks found in a given file-based Block Template, introduce a new function called `_inject_theme_attribute_in_template_part_block`, and use that as second argument to `serialize_blocks()` (introduced in [56557]) in order to inject said attribute during tree traversal for serialization.

This allows for a more modular approach that will eventually be extended to implement automatic insertion of hooked blocks.

Note that we're guarding `_build_block_template_result_from_file()` (i.e. the callsite of `_inject_theme_attribute_in_template_part_block` and previously of `_inject_theme_attribute_in_block_template_content`) against regressions through additional unit test coverage added in [56562].

Props @gziolo.
Fixes #59338. See #59313.

git-svn-id: https://develop.svn.wordpress.org/trunk@56578 602fd350-edb4-49c9-b593-d223f7449a82
Follow-up to [56578].
Props @mukesh27.
See #59338.

git-svn-id: https://develop.svn.wordpress.org/trunk@56579 602fd350-edb4-49c9-b593-d223f7449a82
Line height was broken for button block and adding spacing.

Props nidhidhandhukiya, shailu25.
Fixes #58443.


git-svn-id: https://develop.svn.wordpress.org/trunk@56580 602fd350-edb4-49c9-b593-d223f7449a82
This revert changes to Twenty Nineteen 'style-rtl.css' file made in [56580] as it auto-generated during the build process.

Unprops karmatosed.
Props costdev.
See #58443.


git-svn-id: https://develop.svn.wordpress.org/trunk@56581 602fd350-edb4-49c9-b593-d223f7449a82
…ompatibility for older core themes.

The `the_header_image_tag` function was introduced in WordPress 4.4 as part of [35594]. It is used in all themes created post WordPress 4.4 that supported header images. The function `get_header_image_tag` continues to get updated with new image features, like lazy loading, async decoding and fetch priority. To ensure our core themes maintain compatibility and benefit from these enhancements, a backward compatibility shim has been applied, integrating the `the_header_image_tag` function into the following core themes:

- Twenty Ten
- Twenty Eleven
- Twenty Twelve
- Twenty Fourteen
- Twenty Sixteen

This change ensures future compatibility and modern image features are applied for header images to these older themes. 

Props spacedmonkey, flixos90, mukesh27.
Fixes #58675.

git-svn-id: https://develop.svn.wordpress.org/trunk@56583 602fd350-edb4-49c9-b593-d223f7449a82
Follow-up to [56578].
See #59338.



git-svn-id: https://develop.svn.wordpress.org/trunk@56584 602fd350-edb4-49c9-b593-d223f7449a82
…passing query caching.

Incorporating a new 'cache_results' parameter into the WP_Term_Query class, this commit empowers developers with the ability to bypass query caches, explicitly triggering database queries when needed.  This brings the `WP_Term_Query` class inline with `WP_Query` and `WP_User_Query` that already have a 'cache_results' parameter.

Update the `term_exists` function to use this new parameter, so the term query caches are not used while importing. 

Props dlh, spacedmonkey, peterwilsoncc.
Fixes #52710.

git-svn-id: https://develop.svn.wordpress.org/trunk@56585 602fd350-edb4-49c9-b593-d223f7449a82
…ass methods.

When various methods parameters in child classes were renamed to `$item` to match the parent class for PHP 8 named parameter support, most of the methods restored the more descriptive, specific name at the beginning for better readability, with several exceptions for methods consisting only of a few lines.

To avoid confusion about why some methods do that and some don't, this commit aims to bring more consistency to the code, specifically in list tables' `::column_default()` methods.

Follow-up to [51728], [51737], [51786].

See #58831.

git-svn-id: https://develop.svn.wordpress.org/trunk@56586 602fd350-edb4-49c9-b593-d223f7449a82
In order to implement Block Hooks, we need to add a new `block_hooks` field to the `WP_Block_Type` class, as well as to block registration related functions, the block types REST API controller, etc.

Props gziolo.
Fixes #59346. See #59313.

git-svn-id: https://develop.svn.wordpress.org/trunk@56587 602fd350-edb4-49c9-b593-d223f7449a82
Follow-up to [56587], [55673]. While working on #59346, it was noted that selectors fiels is not always included in the assertions. While looking at it is was difficult to spot the issue because the random order of how REST API fields where listed.

Reorderd the REST API fields in the test cases to follow the list from the documentation: https://github.com/WordPress/gutenberg/blob/trunk/docs/reference-guides/block-api/block-metadata.md. This way it's going to be easier to maintain the list moving forward.

Props ockham.
See #59346, #59313, #57585.



git-svn-id: https://develop.svn.wordpress.org/trunk@56588 602fd350-edb4-49c9-b593-d223f7449a82
Moved `$updated_notice_args` to be defined before the conditional in which it's used.

Props TobiasBg.
See #57791.

git-svn-id: https://develop.svn.wordpress.org/trunk@56589 602fd350-edb4-49c9-b593-d223f7449a82
Correct usage of `additional_classes` array parameter as if it were a function. Clearly, I'm getting tired and missing things. So many little changes. Follow up to [56573].

Props joedolson.
See #57791.

git-svn-id: https://develop.svn.wordpress.org/trunk@56590 602fd350-edb4-49c9-b593-d223f7449a82
Only shift focus into menu when opening the menu. Check `aria-expanded` value of toggle before moving focus.

Props joedolson.
Fixes #59353.

git-svn-id: https://develop.svn.wordpress.org/trunk@56591 602fd350-edb4-49c9-b593-d223f7449a82
…tion

Props soean.
See #59346.
Follow-up [56587].



git-svn-id: https://develop.svn.wordpress.org/trunk@56592 602fd350-edb4-49c9-b593-d223f7449a82
This commit:
* Adds section headers to the ruleset file.
* Organizes all directives in their respective sections.

No functional changes.

Props jrf.
See #59161.

git-svn-id: https://develop.svn.wordpress.org/trunk@56593 602fd350-edb4-49c9-b593-d223f7449a82
Test files should comply with the naming conventions accepted by PHPUnit, not with the WP naming conventions.

While the `WordPress.File.FileName` sniff makes a best effort to prevent throwing errors for files containing test classes, the recommended manner to deal with test files is to exclude the complete test directory from being subject to this sniff.

This updates the ruleset to follow the recommendation.

Follow-up to [42346], [45607].

Props jrf.
See #59161.

git-svn-id: https://develop.svn.wordpress.org/trunk@56594 602fd350-edb4-49c9-b593-d223f7449a82
…e lookup.

                    
In the get_option function, a cache lookup for the notoptions key is performed, which stores an array of keys for options known not to exist. This optimization prevents repeated database queries when certain options are requested. However, the cache lookup for notoptions was conducted before checking if the requested option exists in the cache. Given that it's more likely that the option does exist, this commit reorders the checks to first verify the option's existence in the cache before confirming its absence. This adjustment reduces redundant queries and also eliminates an unnecessary cache lookup, improving overall performance.

Props spacedmonkey, costdev, flixos90, azaozz.
Fixes #58277.

git-svn-id: https://develop.svn.wordpress.org/trunk@56595 602fd350-edb4-49c9-b593-d223f7449a82
@adamsilverstein
Copy link
Owner

:) Thanks! Something is off here:
image

I'll try using the patch you provided though, thanks!

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