mirror of
https://github.com/SocksPls/hltv-api
synced 2025-05-01 15:59:36 +00:00
Removed redundant code
This commit is contained in:
parent
97f9f108c3
commit
30404fbd8f
1 changed files with 1 additions and 1 deletions
2
main.py
2
main.py
|
@ -55,7 +55,7 @@ def top_players():
|
||||||
for player_elem in box.select("> div"):
|
for player_elem in box.select("> div"):
|
||||||
player = {}
|
player = {}
|
||||||
player_link = player_elem.find('a')
|
player_link = player_elem.find('a')
|
||||||
player['name'] = player_link.text.replace(")", ") ")
|
player['name'] = player_link.text
|
||||||
p_url = player_link['href']
|
p_url = player_link['href']
|
||||||
player['player-id'] = converters.to_int(p_url[p_url.index('playerid=')+9:p_url.index('&statsfilter')])
|
player['player-id'] = converters.to_int(p_url[p_url.index('playerid=')+9:p_url.index('&statsfilter')])
|
||||||
player['stat'] = player_elem.select('div:nth-of-type(2)')[0].text
|
player['stat'] = player_elem.select('div:nth-of-type(2)')[0].text
|
||||||
|
|
Loading…
Add table
Reference in a new issue