From 3c88ac14eed5de40712e71ed696725cef974667b Mon Sep 17 00:00:00 2001 From: Peter Westwood Date: Sun, 24 Jan 2016 15:28:40 +0000 Subject: [PATCH] i18n tools: Add the text domain to translate_nooped_plural() calls as well. Fixes #34126 props jrf. git-svn-id: https://develop.svn.wordpress.org/trunk@36390 602fd350-edb4-49c9-b593-d223f7449a82 --- tools/i18n/add-textdomain.php | 1 + tools/i18n/t/data/add-textdomain-0-result.php | 1 + tools/i18n/t/data/add-textdomain-0.php | 1 + 3 files changed, 3 insertions(+) diff --git a/tools/i18n/add-textdomain.php b/tools/i18n/add-textdomain.php index 03a07a3cb0..7712ae28e1 100644 --- a/tools/i18n/add-textdomain.php +++ b/tools/i18n/add-textdomain.php @@ -20,6 +20,7 @@ class AddTextdomain { function __construct() { $makepot = new MakePOT; $this->funcs = array_keys( $makepot->rules ); + $this->funcs[] = 'translate_nooped_plural'; } /** diff --git a/tools/i18n/t/data/add-textdomain-0-result.php b/tools/i18n/t/data/add-textdomain-0-result.php index 4c20cb890e..a6a1257b97 100755 --- a/tools/i18n/t/data/add-textdomain-0-result.php +++ b/tools/i18n/t/data/add-textdomain-0-result.php @@ -14,4 +14,5 @@ function call_some_i18n_methods() { esc_html_e( 'HTML' , 'test-domain'); esc_attr_x( 'Attribute', 'Testing' , 'test-domain'); esc_html_x( 'HTML', 'Testing' , 'test-domain'); + translate_nooped_plural( 'Plural Noop', 2 , 'test-domain'); } \ No newline at end of file diff --git a/tools/i18n/t/data/add-textdomain-0.php b/tools/i18n/t/data/add-textdomain-0.php index f0555926f9..de60e31cf9 100755 --- a/tools/i18n/t/data/add-textdomain-0.php +++ b/tools/i18n/t/data/add-textdomain-0.php @@ -14,4 +14,5 @@ function call_some_i18n_methods() { esc_html_e( 'HTML' ); esc_attr_x( 'Attribute', 'Testing' ); esc_html_x( 'HTML', 'Testing' ); + translate_nooped_plural( 'Plural Noop', 2 ); } \ No newline at end of file