mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2025-12-24 12:19:41 +00:00
Treat falsy values as valid for i18n placeholders & fix groups in common message
This commit is contained in:
@@ -145,13 +145,14 @@ export function setupI18n(
|
||||
}
|
||||
|
||||
const placeholderName = match[1];
|
||||
const value = substitutions[placeholderName];
|
||||
if (!value) {
|
||||
let value = substitutions[placeholderName];
|
||||
if (value == null) {
|
||||
log.error(
|
||||
`i18n: Value not provided for placeholder ${placeholderName} in key '${key}'`
|
||||
);
|
||||
value = '';
|
||||
}
|
||||
builder += value || '';
|
||||
builder += value;
|
||||
|
||||
lastTextIndex = FIND_REPLACEMENTS.lastIndex;
|
||||
match = FIND_REPLACEMENTS.exec(message);
|
||||
|
||||
Reference in New Issue
Block a user