Browse Source

message when fallback to other language

tags/4.1.9.0
Student Main 5 years ago
parent
commit
e4237c8ec7
1 changed files with 3 additions and 4 deletions
  1. +3
    -4
      shadowsocks-csharp/Controller/I18N.cs

+ 3
- 4
shadowsocks-csharp/Controller/I18N.cs View File

@@ -43,19 +43,18 @@ namespace Shadowsocks.Controller
for (int i = 0; i < localeNames.Length; i++) for (int i = 0; i < localeNames.Length; i++)
{ {
if (localeNames[i].Split('-')[0] == localeNoRegion) if (localeNames[i].Split('-')[0] == localeNoRegion)
{
targetIndex = i; targetIndex = i;
}
} }
Logging.Info($"Using {localeNames[targetIndex]} translation for {locale}");
} }
// Still not found, exit // Still not found, exit
if (targetIndex == -1)
if (targetIndex == -1 || enIndex == targetIndex)
{ {
Logging.Info($"Translation for {locale} not found"); Logging.Info($"Translation for {locale} not found");
return; return;
} }
// read translation lines // read translation lines
while (!csvParser.EndOfData) while (!csvParser.EndOfData)
{ {


Loading…
Cancel
Save