bandcamp-fetch
Advanced tools
Comparing version 0.1.0-a-20210213.2 to 0.1.0-a-20210213.3
@@ -161,27 +161,18 @@ const cheerio = require('cheerio'); | ||
basic.albumRelease.forEach( release => { | ||
album.releases.push({ | ||
const releaseItem = { | ||
name: release.name, | ||
url: release.url, | ||
url: null, | ||
format: release.musicReleaseFormat, | ||
description: release.description || '', | ||
imageUrl: utils.reformatImageUrl(release.image, opts.albumImageFormat) | ||
}); | ||
} | ||
if (release.url) { | ||
releaseItem.url = !utils.isAbsoluteUrl(release.url) ? utils.getUrl(release.url, album.url) : release.url; | ||
} | ||
album.releases.push(releaseItem); | ||
}); | ||
} | ||
if (Array.isArray(basic.track.itemListElement)) { | ||
const _getStreamUrl = (url) => { | ||
let file = null; | ||
if (Array.isArray(extra.trackinfo)) { | ||
extra.trackinfo.every( track => { | ||
if (url.endsWith(track.title_link)) { | ||
file = track.file && track.file['mp3-128'] ? track.file['mp3-128'] : null; | ||
return false; | ||
} | ||
return true; | ||
}); | ||
} | ||
return file; | ||
} | ||
basic.track.itemListElement.forEach( track => { | ||
let trackUrl = track.item.url; | ||
let trackUrl = track.item['@id']; | ||
if (!utils.isAbsoluteUrl(trackUrl)) { | ||
@@ -235,3 +226,3 @@ trackUrl = utils.getUrl(trackUrl, album.url); | ||
name: basic.name, | ||
url: basic.url, | ||
url: basic['@id'], | ||
imageUrl: opts.imageBaseUrl + '/img/a' + extra.art_id + '_' + opts.albumImageFormat.id + '.jpg', | ||
@@ -238,0 +229,0 @@ releaseDate: extra.current.release_date, |
{ | ||
"name": "bandcamp-fetch", | ||
"version": "0.1.0a-20210213.2", | ||
"version": "0.1.0a-20210213.3", | ||
"description": "JS library for scraping Bandcamp content", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
357251
1956