mirror of
https://github.com/JustArchiNET/ArchiSteamFarm.git
synced 2026-01-01 14:10:53 +00:00
Use more correct way for resolving #3087
This commit is contained in:
@@ -2183,11 +2183,13 @@ public sealed class ArchiWebHandler : IDisposable {
|
||||
|
||||
ArgumentException.ThrowIfNullOrEmpty(accessToken);
|
||||
|
||||
if (Initialized) {
|
||||
DateTime triggeredAt = DateTime.UtcNow;
|
||||
string steamLoginSecure = $"{steamID}||{accessToken}";
|
||||
|
||||
if (triggeredAt <= SessionValidUntil) {
|
||||
// Assume session is still valid
|
||||
if (Initialized) {
|
||||
string? previousSteamLoginSecure = WebBrowser.CookieContainer.GetCookieValue(SteamCommunityURL, "steamLoginSecure");
|
||||
|
||||
if (previousSteamLoginSecure == steamLoginSecure) {
|
||||
// We have nothing to update, skip this request
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@@ -2201,8 +2203,6 @@ public sealed class ArchiWebHandler : IDisposable {
|
||||
WebBrowser.CookieContainer.Add(new Cookie("sessionid", sessionID, "/", $".{SteamHelpURL.Host}"));
|
||||
WebBrowser.CookieContainer.Add(new Cookie("sessionid", sessionID, "/", $".{SteamStoreURL.Host}"));
|
||||
|
||||
string steamLoginSecure = $"{steamID}||{accessToken}";
|
||||
|
||||
WebBrowser.CookieContainer.Add(new Cookie("steamLoginSecure", steamLoginSecure, "/", $".{SteamCheckoutURL.Host}"));
|
||||
WebBrowser.CookieContainer.Add(new Cookie("steamLoginSecure", steamLoginSecure, "/", $".{SteamCommunityURL.Host}"));
|
||||
WebBrowser.CookieContainer.Add(new Cookie("steamLoginSecure", steamLoginSecure, "/", $".{SteamHelpURL.Host}"));
|
||||
|
||||
Reference in New Issue
Block a user