chore: debug

This commit is contained in:
Cory Dransfeldt 2024-04-23 15:36:22 -07:00
parent 0c5ada745e
commit 1b7a607b56
No known key found for this signature in database

View file

@ -56,6 +56,11 @@ export default async (request) => {
timestamp, timestamp,
genre: artistsMap[artistSanitizedKey(artist)]?.['genre'] || '' genre: artistsMap[artistSanitizedKey(artist)]?.['genre'] || ''
} }
console.log(artistsMap[artistSanitizedKey(artist)])
console.log(artistsMap[artistSanitizedKey(artist)]?.['genre'])
console.log(artistsMap[artistSanitizedKey(artist)]?.['mbid'])
const scrobbleData = await scrobbles.get(`${weekKey()}`, { type: 'json'}) const scrobbleData = await scrobbles.get(`${weekKey()}`, { type: 'json'})
const windowData = await scrobbles.get('window', { type: 'json'}) const windowData = await scrobbles.get('window', { type: 'json'})
const artistUrl = (artistsMap[artistSanitizedKey(artist)]?.['mbid'] && artistsMap[artistSanitizedKey(artist)]?.['mbid'] !== '') ? `http://musicbrainz.org/artist/${artistsMap[artistSanitizedKey(artist)]?.['mbid']}` : `https://musicbrainz.org/search?query=${artist.replace( const artistUrl = (artistsMap[artistSanitizedKey(artist)]?.['mbid'] && artistsMap[artistSanitizedKey(artist)]?.['mbid'] !== '') ? `http://musicbrainz.org/artist/${artistsMap[artistSanitizedKey(artist)]?.['mbid']}` : `https://musicbrainz.org/search?query=${artist.replace(