diff options
author | Lukas Reschke <lukas@owncloud.com> | 2015-02-20 16:35:53 +0100 |
---|---|---|
committer | Lukas Reschke <lukas@owncloud.com> | 2015-02-20 16:35:53 +0100 |
commit | df2e712a8e84b3e12d5a54e3526ab996791e658e (patch) | |
tree | a9645ed626dde14d613654b1b090539273e8ed0b | |
parent | 6e9a2515eaa38eb949fd6d406e03e47c6360b66c (diff) | |
parent | 602845f33eb8cc0d74a078cf0af9f0fbff5ba6cd (diff) | |
download | nextcloud-server-df2e712a8e84b3e12d5a54e3526ab996791e658e.tar.gz nextcloud-server-df2e712a8e84b3e12d5a54e3526ab996791e658e.zip |
Merge pull request #14325 from owncloud/fix-plurals-with-quotes
Correctly create the expected key for plurals with quotes
-rw-r--r-- | l10n/l10n.pl | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/l10n/l10n.pl b/l10n/l10n.pl index 26ed4ecba30..4f8d8debb8d 100644 --- a/l10n/l10n.pl +++ b/l10n/l10n.pl @@ -153,8 +153,11 @@ elsif( $task eq 'write' ){ elsif( defined( $string->msgstr_n() )){ # plural translations my @variants = (); - my $identifier = $string->msgid()."::".$string->msgid_plural(); - $identifier =~ s/"/_/g; + my $msgid = $string->msgid(); + $msgid =~ s/^"(.*)"$/$1/; + my $msgid_plural = $string->msgid_plural(); + $msgid_plural =~ s/^"(.*)"$/$1/; + my $identifier = "_" . $msgid."_::_".$msgid_plural . "_"; foreach my $variant ( sort { $a <=> $b} keys( %{$string->msgstr_n()} )){ push( @variants, $string->msgstr_n()->{$variant} ); |