[wp-trac] [WordPress Trac] #56187: Wrong type in ngettext et al. filter description
WordPress Trac
noreply at wordpress.org
Sat Jul 9 12:27:42 UTC 2022
#56187: Wrong type in ngettext et al. filter description
----------------------------+-----------------------------
Reporter: cyrillbolliger | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: I18N | Version: 6.0
Severity: trivial | Keywords:
Focuses: docs |
----------------------------+-----------------------------
This ticket applies to `wp-includes/l10n.php`. It addresses only a
documentation problem, the code works correctly.
The argument type of the {{{$number}}} argument of the following filters
should be {{{integer}}} instead of {{{string}}} (in the docblock of the
filter):
- {{{ngettext}}}
- {{{ngettext_{$domain} }}}
- {{{ngettext_with_context}}}
- {{{ngettext_with_context_{$domain} }}}
Else it contradicts the docblock of the following functions:
- {{{_n()}}}
- {{{_nx()}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/56187>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list