mirror of
https://github.com/DoctorMcKay/node-steamcommunity.git
synced 2026-08-19 13:13:28 +08:00
Compare commits
6 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e16136866c | ||
|
|
cae85433f9 | ||
|
|
ba6e29c935 | ||
|
|
de95e25867 | ||
|
|
e1820efeca | ||
|
|
7cee24199f |
@@ -590,7 +590,7 @@ SteamCommunity.prototype.getUserInventoryContents = function(userID, appID, cont
|
||||
},
|
||||
"qs": {
|
||||
"l": language, // Default language
|
||||
"count": 2000, // Max items per 'page'
|
||||
"count": 5000, // Max items per 'page'
|
||||
"start_assetid": start
|
||||
},
|
||||
"json": true
|
||||
|
||||
14
index.js
14
index.js
@@ -154,16 +154,20 @@ SteamCommunity.prototype._setCookie = function(cookie, secure) {
|
||||
var protocol = secure ? "https" : "http";
|
||||
cookie.secure = !!secure;
|
||||
|
||||
this._jar.setCookie(cookie.clone(), protocol + "://steamcommunity.com");
|
||||
this._jar.setCookie(cookie.clone(), protocol + "://store.steampowered.com");
|
||||
this._jar.setCookie(cookie.clone(), protocol + "://help.steampowered.com");
|
||||
if (cookie.domain) {
|
||||
this._jar.setCookie(cookie.clone(), protocol + '://' + cookie.domain);
|
||||
} else {
|
||||
this._jar.setCookie(cookie.clone(), protocol + "://steamcommunity.com");
|
||||
this._jar.setCookie(cookie.clone(), protocol + "://store.steampowered.com");
|
||||
this._jar.setCookie(cookie.clone(), protocol + "://help.steampowered.com");
|
||||
}
|
||||
};
|
||||
|
||||
SteamCommunity.prototype.setCookies = function(cookies) {
|
||||
cookies.forEach((cookie) => {
|
||||
var cookieName = cookie.match(/(.+)=/)[1];
|
||||
var cookieName = cookie.trim().split('=')[0];
|
||||
if (cookieName == 'steamLogin' || cookieName == 'steamLoginSecure') {
|
||||
this.steamID = new SteamID(cookie.match(/=(\d+)/)[1]);
|
||||
this.steamID = new SteamID(cookie.match(/steamLogin(Secure)?=(\d+)/)[2]);
|
||||
}
|
||||
|
||||
this._setCookie(Request.cookie(cookie), !!(cookieName.match(/^steamMachineAuth/) || cookieName.match(/Secure$/)));
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "steamcommunity",
|
||||
"version": "3.48.0",
|
||||
"version": "3.48.2",
|
||||
"description": "Provides an interface for logging into and interacting with the Steam Community website",
|
||||
"files": [
|
||||
"/classes",
|
||||
@@ -33,7 +33,7 @@
|
||||
"cheerio": "0.22.0",
|
||||
"image-size": "^0.8.2",
|
||||
"request": "^2.88.0",
|
||||
"steam-session": "^1.6.0",
|
||||
"steam-session": "^1.7.2",
|
||||
"steam-totp": "^1.5.0",
|
||||
"steamid": "^1.1.3",
|
||||
"xml2js": "^0.6.2"
|
||||
|
||||
Reference in New Issue
Block a user