Make WordPress Core

Opened 4 months ago

Last modified 19 hours ago

#62281 new task (blessed)

Docblock improvements for WP 6.8

Reported by: desrosj's profile desrosj Owned by:
Milestone: 6.8 Priority: normal
Severity: normal Version:
Component: General Keywords: has-patch
Focuses: coding-standards Cc:

Description

Previously:

Change History (17)

#1 @SergeyBiryukov
4 months ago

In 59291:

Docs: Adjust comments about set_time_limit() per the documentation standards.

Includes splitting long comments into multiple lines and moving a few comments above the function_exists() check for more consistent placement.

Follow-up to [59039], [59288].

See #62281.

#2 @SergeyBiryukov
4 months ago

In 59333:

Docs: Correct @param tag in untrailingslashit() to match the parameter name.

Follow-up to [54927].

Props justlevine.
See #52217, #62281.

#3 @SergeyBiryukov
4 months ago

In 59334:

Docs: Correct @param type in fix_phpmailer_messageid().

Follow-up to [48033].

Props justlevine.
See #52217, #62281.

#4 @SergeyBiryukov
4 months ago

In 59336:

Docs: Add missing void to DocBlock @return types.

This commit adds missing void return types to (parent) methods that can explicitly return void as one of their conditional paths.

Addressed methods:

  • WP_Privacy_Requests_Table::column_status()
  • WP_Recovery_Mode::handle_error()
  • WP_Widget::form() — unlike the others, it's the child classes that return void when the method is correctly implemented.

Note: @return void (where void is the single type returned) should not be used outside the default bundled themes and the PHP compatibility shims included in WordPress Core, as per the documentation standards.

Follow-up to [30382], [42967], [43256], [44973], [45448].

Props justlevine.
See #52217, #62281.

#5 @johnbillion
3 months ago

In 59405:

Docs: Correct the spelling of silicon in the local development environment readme.

See #62281

This ticket was mentioned in Slack in #core by jonsurrell. View the logs.


2 months ago

This ticket was mentioned in PR #7990 on WordPress/wordpress-develop by @jonsurrell.


2 months ago
#7

  • Keywords has-patch added

The `script_module_data_{$module_id}` filter documentation is truncated.. It seems that the example tag is not processed and instead ends the description section of the documentation.

Change the examples for this filter to use Example: and an indented code block. This seems to work in other places:

https://github.com/WordPress/wordpress-develop/blob/b6f639737c5fa722dd5a80f0ad94e48c67c37ffd/src/wp-includes/functions.php#L7514-L7525

Trac ticket: https://core.trac.wordpress.org/ticket/62281

#8 @SergeyBiryukov
2 months ago

In 59505:

Docs: Correct formatting for script module data filter documentation examples.

Follow-up to [58579].

Props jonsurrell.
See #62281.

@SergeyBiryukov commented on PR #7990:


2 months ago
#9

Thanks for the PR! Merged in r59505.

#10 @audrasjb
2 months ago

In 59549:

Docs: Docblock improvements in .

Props shailu25.
Fixes #62730.
See #62281.

#11 @audrasjb
3 weeks ago

In 59702:

Docs: Various Docblock fixes in wp-includes/widgets.php, as per WP Docs standards;

Props ankitpatel1578, sabernhardt.
Fixes #62859.
See #62281.

#12 @audrasjb
3 weeks ago

In 59704:

Docs: Improve @return docblock section for get_category().

This changeset adds more details on the WP_Term returned by get_category() as it contains additional backwards compatible aliases for the era before WP 4.4 and 2.3.

Props apermo, audrasjb.
Fixes #62842.
See #62281.

#13 @audrasjb
3 weeks ago

In 59734:

Docs: Improve docblock for rest_menu_read_access filter.

Follow-up to [59718].

See #62281, #54304.

#14 @SergeyBiryukov
2 weeks ago

In 59756:

Docs: Correct DocBlock formatting for the_password_form filter.

Follow-up to [59736], [59737].

See #62281.

#15 @audrasjb
10 days ago

In 59785:

Docs: Various Docblock fixes in wp-includes/class-wp-customize-control.php, as per WP Docs standards;

See #62281.

#16 @audrasjb
10 days ago

In 59787:

Docs: Fix Docblock parameters indentation for wp_determine_option_autoload_value(), as per WP Docs standards.

See #62281.

#17 @SergeyBiryukov
19 hours ago

In 59829:

Docs: Correct formatting for get_the_date and get_the_time DocBlocks.

Follow-up to [53000].

See #62281.

Note: See TracTickets for help on using tickets.