Skip to content

Docs: Fix inline comment typos in build_query_vars_from_query_block() in blocks.php #11851

Open
deepakrohillas wants to merge 66 commits into
WordPress:trunkfrom
deepakrohillas:typo_wp_includes_blocks_dot_php
Open

Docs: Fix inline comment typos in build_query_vars_from_query_block() in blocks.php #11851
deepakrohillas wants to merge 66 commits into
WordPress:trunkfrom
deepakrohillas:typo_wp_includes_blocks_dot_php

Conversation

@deepakrohillas
Copy link
Copy Markdown

@deepakrohillas deepakrohillas commented May 18, 2026

https://core.trac.wordpress.org/ticket/65259
In src/wp-includes/blocks.php, the inline comment inside build_query_vars_from_query_block() contains two errors: (1) "before hand" should be "beforehand" (compound adverb), and It detects when a path to file was provided from this "It" should be removed.

WordPress inline documentation standards, especially for DocBlocks.
In WordPress coding standards:
The description section should continue naturally and should not start with “It”.

… add_action()

`error.message` LIKE 'Uncaught exception 'Error' with message 'Call to undefined function add_action()' in /var/www/wp-content/plugins/hello.php:69%' AND `error.class` = 'Error' AND transactionUiName = '/wp-content/plugins/hello.php'

'request_uri': '/wp-content/plugins/hello.php'
…dolly_uncaught_exception

Fix Uncaught exception Error with message 'Call to undefined function…
Plugin URI http to https change
@github-actions
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.

Core Committers: Use this line as a base for the props when committing in SVN:

Props deepakrohilla, audrasjb.

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

@deepakrohillas deepakrohillas changed the title Typo wp includes blocks dot php Docs: Fix inline comment typos in build_query_vars_from_query_block() in blocks.php May 18, 2026
@github-actions
Copy link
Copy Markdown

Test using WordPress Playground

The changes in this pull request can previewed and tested using a WordPress Playground instance.

WordPress Playground is an experimental project that creates a full WordPress instance entirely within the browser.

Some things to be aware of

  • All changes will be lost when closing a tab with a Playground instance.
  • All changes will be lost when refreshing the page.
  • A fresh instance is created each time the link below is clicked.
  • Every time this pull request is updated, a new ZIP file containing all changes is created. If changes are not reflected in the Playground instance,
    it's possible that the most recent build failed, or has not completed. Check the list of workflow runs to be sure.

For more details about these limitations and more, check out the Limitations page in the WordPress Playground documentation.

Test this pull request with WordPress Playground.

Copy link
Copy Markdown
Member

@westonruter westonruter left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

Curious why there are so many commits in this PR?

Copy link
Copy Markdown

@sabernhardt sabernhardt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similarly, the docblocks for register_block_script_handle() and register_block_style_handle() probably should change "It detects" too.

Comment on lines +133 to 136
* Detects when a path to file was provided and optionally finds a corresponding asset
* file with details necessary to register the script module under with an
* automatically generated module ID. It returns unprocessed script module
* ID otherwise.
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove "under" and wrap the lines at 80 characters:

Suggested change
* Detects when a path to file was provided and optionally finds a corresponding asset
* file with details necessary to register the script module under with an
* automatically generated module ID. It returns unprocessed script module
* ID otherwise.
* Detects when a path to file was provided and optionally finds a corresponding
* asset file with details necessary to register the script module with an
* automatically generated module ID. It returns unprocessed script module ID
* otherwise.

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.

4 participants