Skip to content

Commit

Permalink
Add PC property from crush field to notes
Browse files Browse the repository at this point in the history
  • Loading branch information
TLNBS2405 committed Mar 31, 2024
1 parent 4f3d60b commit c155369
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions src/frame_service/wavu/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@ def _get_wavu_response(session: requests.Session, character_name: CharacterName,


def _get_wavu_character_movelist(
content: Any,
format: str = "json",
content: Any,
format: str = "json",
) -> Dict[str, Move]:
"""
Get the movelist for a character from a Wavu API response
Expand Down Expand Up @@ -142,6 +142,13 @@ def _convert_json_move(move_json: Any) -> WavuMove:
video = ""

notes = _remove_html_tags(_process_links(move_json["notes"])).strip()
crush = _normalize_data(move_json["crush"])
if "pc" in crush:
notes += "\n* Power Crush"
if "js" in crush:
notes += "\n"
if "cs" in crush:
notes += "\n" + crush

move = WavuMove(
id,
Expand Down

0 comments on commit c155369

Please sign in to comment.