mirror of
https://github.com/JustArchiNET/ArchiSteamFarm.git
synced 2026-01-16 08:25:28 +00:00
Share HttpClient with SK2 WebAPI
This commit is contained in:
@@ -93,6 +93,7 @@ namespace ArchiSteamFarm {
|
||||
|
||||
internal readonly ConcurrentDictionary<uint, (EPaymentMethod PaymentMethod, DateTime TimeCreated)> OwnedPackageIDs = new ConcurrentDictionary<uint, (EPaymentMethod PaymentMethod, DateTime TimeCreated)>();
|
||||
internal readonly SteamApps SteamApps;
|
||||
internal readonly SteamConfiguration SteamConfiguration;
|
||||
internal readonly SteamFriends SteamFriends;
|
||||
|
||||
internal bool CanReceiveSteamCards => !IsAccountLimited && !IsAccountLocked;
|
||||
@@ -213,10 +214,10 @@ namespace ArchiSteamFarm {
|
||||
|
||||
ArchiWebHandler = new ArchiWebHandler(this);
|
||||
|
||||
SteamConfiguration steamConfiguration = SteamConfiguration.Create(builder => builder.WithProtocolTypes(ASF.GlobalConfig.SteamProtocols).WithCellID(ASF.GlobalDatabase.CellID).WithServerListProvider(ASF.GlobalDatabase.ServerListProvider).WithHttpClientFactory(() => ArchiWebHandler.GenerateDisposableHttpClient()));
|
||||
SteamConfiguration = SteamConfiguration.Create(builder => builder.WithProtocolTypes(ASF.GlobalConfig.SteamProtocols).WithCellID(ASF.GlobalDatabase.CellID).WithServerListProvider(ASF.GlobalDatabase.ServerListProvider).WithHttpClientFactory(ArchiWebHandler.GenerateDisposableHttpClient));
|
||||
|
||||
// Initialize
|
||||
SteamClient = new SteamClient(steamConfiguration);
|
||||
SteamClient = new SteamClient(SteamConfiguration);
|
||||
|
||||
if (Debugging.IsUserDebugging && Directory.Exists(SharedInfo.DebugDirectory)) {
|
||||
string debugListenerPath = Path.Combine(SharedInfo.DebugDirectory, botName);
|
||||
|
||||
Reference in New Issue
Block a user