mirror of
https://github.com/JustArchiNET/ArchiSteamFarm.git
synced 2026-01-06 17:10:13 +00:00
Run API calls in their own tasks
Those SK2 calls are synchronous after all, and they might affect responsiveness negatively when a single bot is executing many of them. This is once again not a problem of ASF, as here we can have like 1-2 concurrent API calls, but ArchiBoT suffered from this a lot.
This commit is contained in:
@@ -366,7 +366,7 @@ namespace ArchiSteamFarm {
|
||||
return (uint) (Utilities.GetUnixTime() + SteamTimeDifference.Value);
|
||||
}
|
||||
|
||||
uint serverTime = Bot.ArchiWebHandler.GetServerTime();
|
||||
uint serverTime = await Bot.ArchiWebHandler.GetServerTime().ConfigureAwait(false);
|
||||
if (serverTime == 0) {
|
||||
return Utilities.GetUnixTime();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user