mirror of
https://github.com/DoctorMcKay/node-steamcommunity.git
synced 2025-03-05 00:10:20 +08:00
Merge pull request #189 from Aareksio/patch-1
Fix infinite loop in getWebApiKey
This commit is contained in:
commit
c38111b61a
@ -15,6 +15,10 @@ SteamCommunity.prototype.getWebApiKey = function(domain, callback) {
|
|||||||
return callback(new Error("Access Denied"));
|
return callback(new Error("Access Denied"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(body.match(/You must have a validated email address to create a Steam Web API key./)) {
|
||||||
|
return callback(new Error("You must have a validated email address to create a Steam Web API key."));
|
||||||
|
}
|
||||||
|
|
||||||
var match = body.match(/<p>Key: ([0-9A-F]+)<\/p>/);
|
var match = body.match(/<p>Key: ([0-9A-F]+)<\/p>/);
|
||||||
if(match) {
|
if(match) {
|
||||||
// We already have an API key registered
|
// We already have an API key registered
|
||||||
|
Loading…
Reference in New Issue
Block a user