mirror of
https://github.com/tcsenpai/swingmusic.git
synced 2025-06-07 03:35:35 +00:00
fix inheritance in Artist model class
This commit is contained in:
parent
fe6c12d856
commit
805df18ac3
@ -27,15 +27,15 @@ class Artist(ArtistMinimal):
|
||||
Artist class
|
||||
"""
|
||||
|
||||
name: str = ""
|
||||
trackcount: int = 0
|
||||
albumcount: int = 0
|
||||
duration: int = 0
|
||||
colors: list[str] = dataclasses.field(default_factory=list)
|
||||
is_favorite: bool = False
|
||||
|
||||
def __init__(self, name: str):
|
||||
super(Artist, self).__init__(name)
|
||||
self.colors = json.loads(str(self.colors))
|
||||
def __post_init__(self):
|
||||
super(Artist, self).__init__(self.name)
|
||||
|
||||
def set_trackcount(self, count: int):
|
||||
self.trackcount = count
|
||||
|
Loading…
x
Reference in New Issue
Block a user