fix soundcloud downloading
This commit is contained in:
parent
5ec7596f87
commit
18b932925d
2 changed files with 9 additions and 1 deletions
|
|
@ -127,6 +127,14 @@ class SoundcloudAlbum(Entry):
|
|||
"""Returns the album's year, computed by the max upload year amongst all album tracks"""
|
||||
return max(track.upload_year for track in self._single_tracks)
|
||||
|
||||
@property
|
||||
def track_count(self) -> int:
|
||||
return self.kwargs('playlist_count')
|
||||
|
||||
@property
|
||||
def downloaded_track_count(self) -> int:
|
||||
return len(self.kwargs("entries"))
|
||||
|
||||
def contains(self, track: SoundcloudTrack) -> bool:
|
||||
"""Returns whether the album contains a track"""
|
||||
return any(track.uid == t.uid for t in self._single_tracks)
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ class SoundcloudSubscription(Subscription[SourceT], ABC):
|
|||
|
||||
|
||||
class SoundcloudAlbumsAndSinglesSubscription(
|
||||
Subscription[SoundcloudAlbumsAndSinglesSourceValidator]
|
||||
SoundcloudSubscription[SoundcloudAlbumsAndSinglesSourceValidator]
|
||||
):
|
||||
def _extract_info(self) -> List[SoundcloudTrack]:
|
||||
tracks: List[SoundcloudTrack] = []
|
||||
|
|
|
|||
Loading…
Reference in a new issue