mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-09-13 02:42:09 +02:00
L10n (Pt): matches all Portuguese locales, not only bare pt (#2521)
359cb0a79a renamed the key from `pt_BR` to
`pt` but kept the exact-match guard, so only the literal string `pt`
matched. Every real Portuguese locale (`pt_BR`, `pt_PT` and their charset
and modifier variants) fell through to `goto error` and aborted.
Return the offset unconditionally, matching every other two-letter case.
This commit is contained in:
@@ -71,12 +71,7 @@ static uint32_t optionParseLanguageString(FFstrbuf* language) {
|
||||
case 'ja': return offsetof(FFModuleDisplayName, ja);
|
||||
case 'ko': return offsetof(FFModuleDisplayName, ko);
|
||||
case 'pl': return offsetof(FFModuleDisplayName, pl);
|
||||
case 'pt': {
|
||||
if (ffStrbufEqualS(language, "pt")) {
|
||||
return offsetof(FFModuleDisplayName, pt);
|
||||
}
|
||||
goto error;
|
||||
}
|
||||
case 'pt': return offsetof(FFModuleDisplayName, pt);
|
||||
case 'ru': return offsetof(FFModuleDisplayName, ru);
|
||||
case 'zh': {
|
||||
if (ffStrbufEqualS(language, "zh_cn")) {
|
||||
|
||||
Reference in New Issue
Block a user