mirror of
https://github.com/SocksPls/hltv-api
synced 2025-04-30 23:43:08 +00:00
Adds URL to get_matches()
Allows you to get matchid/match page url info out of the API for upcoming matches
This commit is contained in:
parent
b2c500015b
commit
1ce33609cc
1 changed files with 1 additions and 0 deletions
1
main.py
1
main.py
|
@ -232,6 +232,7 @@ def get_matches():
|
||||||
matchObj = {}
|
matchObj = {}
|
||||||
|
|
||||||
matchObj['date'] = date
|
matchObj['date'] = date
|
||||||
|
matchObj['url'] = match.find("a", {"class": "match a-reset"}).get("href")
|
||||||
matchObj['time'] = getMatch.find("div", {"class": "matchTime"}).text
|
matchObj['time'] = getMatch.find("div", {"class": "matchTime"}).text
|
||||||
if getMatch.find("div", {"class": "matchEvent"}):
|
if getMatch.find("div", {"class": "matchEvent"}):
|
||||||
matchObj['event'] = getMatch.find("div", {"class": "matchEvent"}).text.encode('utf8').strip()
|
matchObj['event'] = getMatch.find("div", {"class": "matchEvent"}).text.encode('utf8').strip()
|
||||||
|
|
Loading…
Add table
Reference in a new issue