add coverartwork to playlists

This commit is contained in:
aria 2024-09-06 13:44:48 -04:00
parent c9918250c8
commit 359a7e144a
3 changed files with 4 additions and 3 deletions

View File

@ -1,6 +1,6 @@
{ {
"name": "lucida", "name": "lucida",
"version": "2.0.0-41", "version": "2.0.0-42",
"description": "A modular music downloader tool", "description": "A modular music downloader tool",
"main": "build/index.js", "main": "build/index.js",
"type": "module", "type": "module",

View File

@ -1,6 +1,6 @@
import Spotify from './../build/streamers/spotify/main.js' import Spotify from './../build/streamers/spotify/main.js'
const client = new Spotify({}) const client = new Spotify({ clientId: '9a8d2f0ce77a4e248bb71fefcb557637' })
await client.login(process.env.SPOTIFY_USERNAME, process.env.SPOTIFY_PASSWORD) await client.login(process.env.SPOTIFY_USERNAME, process.env.SPOTIFY_PASSWORD)
const storedCreds = client.getStoredCredentials() const storedCreds = client.getStoredCredentials()

View File

@ -99,7 +99,8 @@ export function parsePlaylist(raw: SpotifyPlaylist) {
id: raw.id, id: raw.id,
title: raw.name, title: raw.name,
url: raw.externalUrl, url: raw.externalUrl,
trackCount: raw.totalTracks trackCount: raw.totalTracks,
coverArtwork: parseThumbnails(raw.coverArtwork)
} }
return playlist return playlist