Skip to content

Commit

Permalink
fix: fixed issue with roles endpoint since Blizzard update (#145)
Browse files Browse the repository at this point in the history
  • Loading branch information
TeKrop authored Jun 23, 2024
1 parent 945c398 commit e6fd7b8
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 14 deletions.
14 changes: 5 additions & 9 deletions app/parsers/roles_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,11 @@ class RolesParser(APIParser):
timeout = settings.heroes_path_cache_timeout

def parse_data(self) -> list[dict]:
roles_container = (
self.root_tag.find("main", recursive=False)
.find(
"div",
class_="homepage-features-heroes",
recursive=False,
)
.find("blz-feature-carousel-section", recursive=False)
)
roles_container = self.root_tag.find(
"div",
class_="homepage-features-heroes",
recursive=False,
).find("blz-feature-carousel-section", recursive=False)

roles_icons = [
role_icon_div.find("blz-image")["src"]
Expand Down
17 changes: 12 additions & 5 deletions tests/fixtures/html/home.html

Large diffs are not rendered by default.

0 comments on commit e6fd7b8

Please sign in to comment.