Fix logical issues found with static analyzer (#828)

* Fix possible logical issues found with static analyzer
Bot:2216 - there is already a null check before
IPC:612 - shouldn't it be 'if' because we get out of the loop anyway?

* Revert IPC.cs change
This commit is contained in:
Vital7
2018-06-25 01:39:02 +03:00
committed by Łukasz Domeradzki
parent 80acfbee17
commit ffad599ea1

View File

@@ -2213,7 +2213,7 @@ namespace ArchiSteamFarm {
}
string loginKey = callback.LoginKey;
if (!string.IsNullOrEmpty(loginKey) && (BotConfig.PasswordFormat != CryptoHelper.ECryptoMethod.PlainText)) {
if (BotConfig.PasswordFormat != CryptoHelper.ECryptoMethod.PlainText) {
loginKey = CryptoHelper.Encrypt(BotConfig.PasswordFormat, loginKey);
}