diff --git a/lib/get-text.js b/lib/get-text.js index 6c6b0754..b8468905 100644 --- a/lib/get-text.js +++ b/lib/get-text.js @@ -99,6 +99,7 @@ export default class GetText { return result( [500, message] ); } + // XXX #parse ( poFile, content, parser, options, file, start ) { try { var ast = parser( content, options ); @@ -283,30 +284,24 @@ export default class GetText { #parseYaml ( poFile, content, file ) { const locale = { - l10n ( msgId, pluralMsgId, pluralNumber ) { + l10n ( msgId, { plural, pluralNumber, domain, tags } = {} ) { poFile.addMessages( { [msgId]: { - "pluralId": pluralMsgId, + "pluralId": plural, "references": [file], + "domains": domain, + tags, }, } ); }, - l10nd ( domain, msgId, pluralMsgId, pluralNumber ) { + l10nt ( msgId, { plural, pluralNumber, domain, tags } = {} ) { poFile.addMessages( { [msgId]: { - "pluralId": pluralMsgId, - "references": [file], - "domains": [domain], - }, - } ); - }, - - l10nt ( msgId, pluralMsgId, pluralNumber ) { - poFile.addMessages( { - [msgId]: { - "pluralId": pluralMsgId, + "pluralId": plural, "references": [file], + "domains": domain, + tags, }, } ); },