WordPress.org

Make WordPress Core

Opened 4 years ago

Closed 4 years ago

#34127 closed task (blessed) (fixed)

Update docblocks for l10n.php

Reported by: johnbillion Owned by: DrewAPicture
Milestone: 4.4 Priority: normal
Severity: normal Version:
Component: I18N Keywords: has-patch
Focuses: docs Cc:
PR Number:

Description


Attachments (1)

34127.diff (15.1 KB) - added by johnbillion 4 years ago.

Download all attachments as: .zip

Change History (4)

@johnbillion
4 years ago

#1 @johnbillion
4 years ago

  • Summary changed from Update docblocks for i10n.php to Update docblocks for l10n.php

34127.diff addresses several issues with the docblocks for our l10n functions.

  • Corrects phrasing used in the descriptions for and filters in _n() and _nx(), particularly with regard to the use of 'singular' instead of 'single' or '1', and 'plural' instead of 'not 1'.
  • Adds example usage to _n(), _nx(), _nx_noop(), and translate_nooped_plural().
  • Adds hash notation @return doc for _n_noop() and _nx_noop().
  • Adds missing default values for the $domain parameter.

#2 @DrewAPicture
4 years ago

  • Keywords has-patch added
  • Owner set to DrewAPicture
  • Status changed from new to reviewing

#3 @DrewAPicture
4 years ago

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

In 34781:

Docs: Improve a variety of inline docs in wp-includes/l10n.php.

  • Corrects phrasing used in the descriptions for and filters in _n() and _nx(), particularly with regard to the use of 'singular' instead of 'single' or '1', and 'plural' instead of 'not 1'.
  • Adds example usage to _n(), _nx(), _nx_noop(), and translate_nooped_plural().
  • Adds hash notation @return doc for _n_noop() and _nx_noop().
  • Adds missing default values for the optional $domain parameter in several places.

Props johnbillion.
Fixes #34127.

Note: See TracTickets for help on using tickets.