mirror of
https://github.com/JustArchiNET/ArchiSteamFarm.git
synced 2026-01-01 06:00:46 +00:00
Closes #2109
This commit is contained in:
@@ -2268,10 +2268,27 @@ namespace ArchiSteamFarm {
|
||||
const string nonAsciiPattern = @"[^\u0000-\u007F]+";
|
||||
|
||||
string username = Regex.Replace(BotConfig.SteamLogin!, nonAsciiPattern, "", RegexOptions.CultureInvariant | RegexOptions.IgnoreCase);
|
||||
|
||||
if (string.IsNullOrEmpty(username)) {
|
||||
ArchiLogger.LogGenericError(string.Format(CultureInfo.CurrentCulture, Strings.ErrorIsInvalid, nameof(BotConfig.SteamLogin)));
|
||||
|
||||
Stop();
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
string? password = BotConfig.DecryptedSteamPassword;
|
||||
|
||||
if (!string.IsNullOrEmpty(password)) {
|
||||
password = Regex.Replace(password!, nonAsciiPattern, "", RegexOptions.CultureInvariant | RegexOptions.IgnoreCase);
|
||||
|
||||
if (string.IsNullOrEmpty(password)) {
|
||||
ArchiLogger.LogGenericError(string.Format(CultureInfo.CurrentCulture, Strings.ErrorIsInvalid, nameof(BotConfig.SteamPassword)));
|
||||
|
||||
Stop();
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
ArchiLogger.LogGenericInfo(Strings.BotLoggingIn);
|
||||
|
||||
Reference in New Issue
Block a user