mirror of
https://github.com/JustArchiNET/ArchiSteamFarm.git
synced 2026-01-01 06:00:46 +00:00
Fix SteamDirectory crash, closes #85
This commit is contained in:
@@ -191,7 +191,17 @@ namespace ArchiSteamFarm {
|
||||
}
|
||||
|
||||
// Before attempting to connect, initialize our list of CMs
|
||||
SteamDirectory.Initialize().Wait();
|
||||
bool initialized = false;
|
||||
while (!initialized) {
|
||||
try {
|
||||
Logging.LogGenericInfo(BotName, "Getting list of CMs...");
|
||||
SteamDirectory.Initialize().Wait();
|
||||
initialized = true;
|
||||
Logging.LogGenericInfo(BotName, "Success!");
|
||||
} catch (TaskCanceledException) {
|
||||
Logging.LogGenericWarning(BotName, "Failed! Retrying...");
|
||||
}
|
||||
}
|
||||
|
||||
// Start
|
||||
var handleCallbacks = Task.Run(() => HandleCallbacks());
|
||||
|
||||
Reference in New Issue
Block a user