WordPress.org

Make WordPress Core

Opened 6 years ago

Closed 6 years ago

Last modified 6 years ago

#25466 closed defect (bug) (fixed)

Hook Docs: wp-includes/vars.php

Reported by: tmtoy Owned by: DrewAPicture
Milestone: 3.7 Priority: normal
Severity: normal Version:
Component: Inline Docs Keywords: needs-patch
Focuses: Cc:
PR Number:

Description (last modified by DrewAPicture)

Attached patch has done for the all hooks in wp-includes/vars.php.

Attachments (2)

vars.diff (1.0 KB) - added by tmtoy 6 years ago.
Patch wp-includes/vars.php
vars-2.diff (970 bytes) - added by tmtoy 6 years ago.
Fixed mistake /wp-includes/vars.php

Download all attachments as: .zip

Change History (13)

@tmtoy
6 years ago

Patch wp-includes/vars.php

#1 @DrewAPicture
6 years ago

  • Description modified (diff)
  • Owner set to DrewAPicture
  • Status changed from new to reviewing
  • Summary changed from Hook Docs: vars.php to Hook Docs: wp-includes/vars.php

#2 @DrewAPicture
6 years ago

  • Keywords needs-patch added; has-patch removed
  • Type changed from enhancement to defect (bug)

Hi, thanks for the patch. Some notes on vars.diff

  • "Filter whether to use google chrome frame." is incorrect. The filters serves more as whether to identify the HTTP_USER_AGENT as Google Chrome.
  • Once you've fixed the short description, match that to the parameter description. Something like, "Whether to allow the HTTP_USER_AGENT to be identified as Google Chrome."
  • Specify the default of the boolean value (in this case, true) at the end of the parameter description.
  • Per [18036], @since should be 3.2.0.

#3 @DrewAPicture
6 years ago

#25499 was marked as a duplicate.

#4 @nacin
6 years ago

It's more like: "Filter to whether Google Chrome Frame should be used, if available."

#5 @tmtoy
6 years ago

Thank you for the lucid Comment!!

  • Fixed the short description to "Filter to whether Google Chrome Frame should be used, if available.".
    (I referenced Mr.nacin's Comment. Thank you.)
  • Added the default of the boolean value.
  • Fixed the @since to "3.2.0".

I'm sorry if I had mistake, Please help me again.

@tmtoy
6 years ago

Fixed mistake /wp-includes/vars.php

#6 @DrewAPicture
6 years ago

  • Resolution set to fixed
  • Status changed from reviewing to closed

In 25712:

Inline documentation for hooks in wp-includes/vars.php.

Props tmtoy, nacin.
Fixes #25466.

#7 follow-up: @tmtoy
6 years ago

Thank you for added to changeset and your supported.
But I have a quetion a little.

Changeset 25712:
trunk/src/wp-includes/vars.php in line 60.
* @param bool $is_admin

There is not $is_admin in this file.
Is not the problem this description?
Is not need break the array out to a boolian variable in apply_filters?

#8 @DrewAPicture
6 years ago

In 25718:

Add missing variable for inline hook documentation changes in wp-includes/vars.php.

See #25466.

#9 in reply to: ↑ 7 @DrewAPicture
6 years ago

Replying to tmtoy:

Thank you for added to changeset and your supported.
But I have a quetion a little.

Changeset 25712:
trunk/src/wp-includes/vars.php in line 60.
* @param bool $is_admin

There is not $is_admin in this file.
Is not the problem this description?
Is not need break the array out to a boolian variable in apply_filters?

It looks like the variable was inadvertently removed prior to the commit (my bad). Fixed in [25718].

#10 @tmtoy
6 years ago

OK! I understand. Thanks!

#11 @dd32
6 years ago

  • Milestone changed from Awaiting Review to 3.7
Note: See TracTickets for help on using tickets.