From 35dcb7288d16cbdf26a625167c71f4bdc2a43ff6 Mon Sep 17 00:00:00 2001 From: killer069 <65385476+killer069@users.noreply.github.com> Date: Mon, 18 Oct 2021 15:38:05 +0530 Subject: [PATCH] Spotify tracksCount name error fixed --- play-dl/Spotify/classes.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/play-dl/Spotify/classes.ts b/play-dl/Spotify/classes.ts index e0643f7..b9b6f7e 100644 --- a/play-dl/Spotify/classes.ts +++ b/play-dl/Spotify/classes.ts @@ -200,7 +200,7 @@ export class SpotifyAlbum { copyrights: SpotifyCopyright[]; release_date: string; release_date_precision: string; - trackCount: number; + tracksCount: number; private spotifyData: SpotifyDataOptions; private fetched_tracks: Map; constructor(data: any, spotifyData: SpotifyDataOptions) { @@ -221,7 +221,7 @@ export class SpotifyAlbum { this.copyrights = data.copyrights; this.release_date = data.release_date; this.release_date_precision = data.release_date_precision; - this.trackCount = data.total_tracks; + this.tracksCount = data.total_tracks; const videos: SpotifyTrack[] = []; data.tracks.items.forEach((v: any) => { videos.push(new SpotifyTrack(v)); @@ -233,8 +233,8 @@ export class SpotifyAlbum { async fetch() { let fetching: number; - if (this.trackCount > 500) fetching = 500; - else fetching = this.trackCount; + if (this.tracksCount > 500) fetching = 500; + else fetching = this.tracksCount; if (fetching <= 50) return; const work = []; for (let i = 2; i <= Math.ceil(fetching / 50); i++) {