In case translation json has empty singular and/or plural strings in the array, the translation function will throw an error.
This could potentionally prevent render of vue component.
getTranslationFromArray function is checking for translation string to be falsy value, so it will throw an error if the translation string is empty. According to gettext manual, empty strings should be treated as untranslated.
This commit fixes by checking that translation string is falsy, but not string. For empty strings error is not thrown and untranslated string returned.
In case translation json has empty singular and/or plural strings in the array, the translation function will throw an error. This could potentionally prevent render of vue component.
getTranslationFromArray function is checking for translation string to be falsy value, so it will throw an error if the translation string is empty. According to gettext manual, empty strings should be treated as untranslated.
This commit fixes by checking that translation string is falsy, but not string. For empty strings error is not thrown and untranslated string returned.