This commit is contained in:
JustArchi
2016-09-20 16:29:13 +02:00
parent dc1ae32d37
commit 0439656499

View File

@@ -143,7 +143,7 @@ namespace ArchiSteamFarm {
}
if (Bots.ContainsKey(botName)) {
throw new Exception("That bot is already defined!");
throw new ArgumentException("That bot is already defined!");
}
string botPath = Path.Combine(SharedInfo.ConfigDirectory, botName);
@@ -259,7 +259,9 @@ namespace ArchiSteamFarm {
}
// Register bot as available for ASF
Bots[botName] = this;
if (!Bots.TryAdd(botName, this)) {
throw new ArgumentException("That bot is already defined!");
}
if (!BotConfig.StartOnLaunch) {
return;