mirror of
https://github.com/DoctorMcKay/node-steamcommunity.git
synced 2025-01-19 07:26:52 +08:00
Handle cases where inventories are private in getUserInventoryContexts
This commit is contained in:
parent
acbd71666b
commit
47dc22ca0d
@ -241,7 +241,7 @@ SteamCommunity.prototype.getUserInventoryContexts = function(userID, callback) {
|
||||
|
||||
var match = body.match(/var g_rgAppContextData = ([^\n]+);\r?\n/);
|
||||
if (!match) {
|
||||
callback(new Error("Malformed response"));
|
||||
callback(new Error(body.match(/inventory is currently private\./) ? "Private inventory" : "Malformed response"));
|
||||
return;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user