Skip to content

Commit a52fcee

Browse files
committed
update documentation (#42)
1 parent 3a66391 commit a52fcee

4 files changed

Lines changed: 32 additions & 32 deletions

File tree

brawlstats/brawlapi/core.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -324,7 +324,7 @@ def search_club(self, club_name: str):
324324
club_name: str
325325
The query for the club search.
326326
327-
Returns List\[PartialClub\]
327+
Returns List[PartialClub]
328328
"""
329329
url = self.api.CLUB_SEARCH + '?name=' + club_name
330330
return self._get_model(url, model=PartialClub)

brawlstats/brawlapi/models.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ def get_club(self, full=True):
5454
full: Optional[bool] = True
5555
Whether or not to get the player's full club stats or not.
5656
57-
Returns None, PartialClub, or Club
57+
Returns Optional[Union[PartialClub, Club]]
5858
"""
5959
if not self.club:
6060
return None

brawlstats/officialapi/models.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ def get_club(self):
4949
"""
5050
Gets the player's club.
5151
52-
Returns None or Club
52+
Returns Optional[Club]
5353
"""
5454
if not self.club:
5555
return None

docs/api.rst

Lines changed: 29 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -45,14 +45,14 @@ A full player object (all its statistics)
4545

4646
Attributes:
4747

48-
============================ =======================
48+
============================ =============
4949
Name Type
50-
============================ =======================
50+
============================ =============
5151
``tag`` str
5252
``name`` str
5353
``name_color_code`` str
5454
``brawlers_unlocked`` int
55-
``brawlers`` List[\Brawler, Brawler]
55+
``brawlers`` List[Brawler]
5656
``victories`` int
5757
``solo_showdown_victories`` int
5858
``duo_showdown_victories`` int
@@ -67,7 +67,7 @@ Name Type
6767
``best_robo_rumble_time`` str
6868
``has_skins`` bool
6969
``club`` PartialClub
70-
============================ =======================
70+
============================ =============
7171

7272
Club
7373
~~~~
@@ -78,9 +78,9 @@ must get it from the client or a player object.
7878

7979
Attributes:
8080

81-
===================== =====================
81+
===================== ============
8282
Name Type
83-
===================== =====================
83+
===================== ============
8484
``tag`` str
8585
``name`` str
8686
``status`` str
@@ -91,8 +91,8 @@ Name Type
9191
``description`` str
9292
``badge_id`` int
9393
``badge_url`` str
94-
``members`` List[\Member, Member]
95-
===================== =====================
94+
``members`` List[Member]
95+
===================== ============
9696

9797
PartialClub
9898
~~~~~~~~~~~
@@ -209,16 +209,16 @@ a profile’s brawler info by getting Profile.brawlers
209209
210210
Attributes:
211211

212-
==================== ===========
212+
==================== =============
213213
Name Type
214-
==================== ===========
214+
==================== =============
215215
``name`` str
216216
``has_skin`` bool
217-
``skin`` str or None
217+
``skin`` Optional[str]
218218
``trophies`` int
219219
``highest_trophies`` int
220220
``power`` int
221-
==================== ===========
221+
==================== =============
222222

223223
Events
224224
~~~~~~
@@ -227,12 +227,12 @@ Returns a result of current and upcoming events.
227227

228228
Attributes:
229229

230-
============ ===================
230+
============ ===========
231231
Name Type
232-
============ ===================
233-
``current`` List[\Event, Event]
234-
``upcoming`` List[\Event, Event]
235-
============ ===================
232+
============ ===========
233+
``current`` List[Event]
234+
``upcoming`` List[Event]
235+
============ ===========
236236

237237
Event Attributes:
238238

@@ -403,9 +403,9 @@ A full player object (all its statistics)
403403

404404
Attributes:
405405

406-
============================ =======================
406+
============================ =============
407407
Name Type
408-
============================ =======================
408+
============================ =============
409409
``name`` str
410410
``name_color`` str
411411
``trophies`` int
@@ -419,8 +419,8 @@ Name Type
419419
``best_time_as_big_brawler`` int
420420
``club.tag`` str
421421
``club.name`` str
422-
``brawlers`` List[\Brawler, Brawler]
423-
============================ =======================
422+
``brawlers`` List[Brawler]
423+
============================ =============
424424

425425
Club
426426
~~~~
@@ -431,17 +431,17 @@ must get it from the client or a player object.
431431

432432
Attributes:
433433

434-
===================== =====================
434+
===================== ============
435435
Name Type
436-
===================== =====================
436+
===================== ============
437437
``tag`` str
438438
``name`` str
439439
``description`` str
440440
``type`` str
441441
``trophies`` int
442442
``required_trophies`` int
443-
``members`` List[\Member, Member]
444-
===================== =====================
443+
``members`` List[Member]
444+
===================== ============
445445

446446
Members
447447
~~~~~~~
@@ -523,17 +523,17 @@ a profile’s brawler info by getting Profile.brawlers
523523
524524
Attributes:
525525

526-
==================== ==============
526+
==================== ========
527527
Name Type
528-
==================== ==============
528+
==================== ========
529529
``id`` int
530530
``name`` str
531531
``power`` int
532532
``rank`` int
533533
``trophies`` int
534534
``highest_trophies`` int
535-
``star_powers`` List\[SP, SP\]
536-
==================== ==============
535+
``star_powers`` List[SP]
536+
==================== ========
537537

538538
Star Power
539539
~~~~~~~~~~

0 commit comments

Comments
 (0)