| Summary: | With i18n() empty strings as arguments seem ignored, placeholder slip into result | ||
|---|---|---|---|
| Product: | [Frameworks and Libraries] frameworks-ki18n | Reporter: | Friedrich W. H. Kossebau <kossebau> |
| Component: | general | Assignee: | Chusslove Illich <caslav.ilic> |
| Status: | REPORTED --- | ||
| Severity: | normal | CC: | aspotashev, kdelibs-bugs-null |
| Priority: | NOR | ||
| Version First Reported In: | 5.20.0 | ||
| Target Milestone: | --- | ||
| Platform: | Other | ||
| OS: | Linux | ||
| Latest Commit: | Version Fixed/Implemented In: | ||
| Sentry Crash Report: | |||
i18n() is part of KF5::I18n |
Seems (in Plasma widget code at least) when arguments which are empty strings are passed to i18n() & friend calls, they are treated as non-existent, resulting in placeholders to survive the replacement and replacements done in wrong places. Examples: i18n("%1", "") -> "%1" i18n("%1-%2", "", "text") -> "text-%2" This happens both for verbatim empty strings and variables containing empty strings. Reproducible: Always