Make WordPress Core

Opened 11 years ago

Closed 11 years ago

#25382 closed enhancement (fixed)

Hook Docs: wp-includes/l10n.php

Reported by: nao's profile Nao Owned by: drewapicture's profile DrewAPicture
Milestone: 3.7 Priority: normal
Severity: normal Version:
Component: Inline Docs Keywords: has-patch commit
Focuses: Cc:

Description

The attached patch adds inline documentation for these hooks.

Filters:
locale
gettext
gettext_with_context
ngettext
ngettext_with_context
override_load_textdomain
load_textdomain_mofile
override_unload_textdomain
theme_locale

Attachments (4)

25382.diff (5.9 KB) - added by Nao 11 years ago.
25382-2.diff (12.8 KB) - added by Nao 11 years ago.
25382.2.diff (6.5 KB) - added by DrewAPicture 11 years ago.
With functional doc changes removed
25382.3.diff (7.0 KB) - added by DrewAPicture 11 years ago.
Documents two actions that were missed

Download all attachments as: .zip

Change History (10)

@Nao
11 years ago

#1 @westi
11 years ago

  • Milestone changed from Awaiting Review to 3.7

#2 @DrewAPicture
11 years ago

Hi Nao,

25382.diff is really close to ready, just a few tweaks:

  • Looks like you missed a @param description for for the plugin_locale and theme_locale filters
  • Change "Optional. Unique identifier for retrieving translated strings." to "Optional. Text domain. Unique identifier for retrieving translated strings." since we're preparing to change it through the rest of the file anyway
  • Closing */ on each block needs to be indented once space
  • Would you mind spacing out the docblocks everywhere the way you did for the gettext and gettext_with_context filters? It really improves readability

I think with those tweaks above this will be ready to go in. Thanks for the patch!

#3 @DrewAPicture
11 years ago

  • Keywords needs-patch added; has-patch removed

@Nao
11 years ago

#4 @Nao
11 years ago

  • Keywords has-patch added; needs-patch removed

Thanks for your review, Drew. Attached is my revised patch based on your feedback.

@DrewAPicture
11 years ago

With functional doc changes removed

#5 @DrewAPicture
11 years ago

  • Keywords commit added

25382.2.diff looks good to me.

@DrewAPicture
11 years ago

Documents two actions that were missed

#6 @DrewAPicture
11 years ago

  • Owner set to DrewAPicture
  • Resolution set to fixed
  • Status changed from new to closed

In 25565:

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

Props Nao.
Fixes #25382.

Note: See TracTickets for help on using tickets.