Skip to content

Commit

Permalink
Merge pull request #1 from dozeworthy/game-list-fix
Browse files Browse the repository at this point in the history
Fix game list acquisition
  • Loading branch information
dozeworthy authored Apr 3, 2023
2 parents 36f069e + 29e9805 commit ab3a841
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion games.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ type Game struct {

// Pattern of game declarations in the public profile. It's actually JSON
// inside Javascript, but this way is easier to extract.
const profileGamePattern = `\{"appid":\s*(\d+),\s*"name":\s*"(.+?)"`
const profileGamePattern = `<appID>(\d+)<\/appID>\s*<name><!\[CDATA\[(.+?)\]\]><\/name>`

// Fetches the list of games from the public user profile. This is better than
// looking locally because the profiles give the full game name, which can be
Expand Down
2 changes: 1 addition & 1 deletion users.go
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ func GetUsers(installationDir string) ([]User, error) {
}

// URL to get the game list from the SteamId64.
const profilePermalinkFormat = `http://steamcommunity.com/profiles/%v/games?tab=all`
const profilePermalinkFormat = `http://steamcommunity.com/profiles/%v/games?xml=1`

// The Steam website has the terrible habit of returning 200 OK when requests
// fail, and signaling the error in HTML. So we have to parse the request to
Expand Down

0 comments on commit ab3a841

Please sign in to comment.