Deprecate 'artist' image format filter; add 'bio'
This commit is contained in:
parent
065a1c1ee0
commit
8e02d3574a
|
@ -68,7 +68,9 @@ You don't have to call this function on params passed to `discover()` - they wil
|
||||||
|
|
||||||
Fetches the list of image formats used in Bandcamp.
|
Fetches the list of image formats used in Bandcamp.
|
||||||
|
|
||||||
- `filter` (optional) - 'artist' or 'album'. If specified, narrows down the result to include only formats applicable to the specified value.
|
- `filter` (optional) - 'bio' (for artist / profile-type images)* or 'album'. If specified, narrows down the result to include only formats applicable to the specified value.
|
||||||
|
|
||||||
|
> The 'artist' filter value is deprecated. Use 'bio' instead.
|
||||||
|
|
||||||
### `getImageFormat(idOrName)`
|
### `getImageFormat(idOrName)`
|
||||||
|
|
||||||
|
|
|
@ -105,7 +105,7 @@ async function getImageFormats(filter = '') {
|
||||||
if (filter === 'album') {
|
if (filter === 'album') {
|
||||||
return constants.formats.filter( c => c.name.startsWith('art_') );
|
return constants.formats.filter( c => c.name.startsWith('art_') );
|
||||||
}
|
}
|
||||||
else if (filter === 'artist') {
|
else if (filter === 'bio' || filter === 'artist') {
|
||||||
return constants.formats.filter( c => c.name.startsWith('bio_') );
|
return constants.formats.filter( c => c.name.startsWith('bio_') );
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user