fix discogarchive lol
This commit is contained in:
parent
979ce211c8
commit
72da2badfe
|
@ -182,7 +182,7 @@ for BANDCAMP_DOMAIN in $BANDCAMP_DOMAINS; do
|
|||
# get album data
|
||||
curl -L -s -o "$RELEASE_PAGE" "$url"
|
||||
pup 'head > script[type="application/ld+json"]' 'text{}' < "$RELEASE_PAGE" > "$JSON_HEAD" || continue
|
||||
pup -p '[data-tralbum] attr{data-tralbum}' 'text{}' < "$RELEASE_PAGE" > "$JSON_TRALBUM" || continue
|
||||
pup -p '[data-tralbum] attr{data-tralbum}' < "$RELEASE_PAGE" > "$JSON_TRALBUM" || continue
|
||||
|
||||
artist="$(jq -r '.byArtist.name' < "$JSON_HEAD")"
|
||||
name="$(jq -r '.name' < "$JSON_HEAD")"
|
||||
|
@ -196,6 +196,7 @@ for BANDCAMP_DOMAIN in $BANDCAMP_DOMAINS; do
|
|||
# check if it even has audio first
|
||||
if [ "$(jq .hasAudio < "$JSON_TRALBUM")" != "true" ]; then
|
||||
errecho "NO AUDIO, LOOK CLOSER: $url"
|
||||
continue
|
||||
fi
|
||||
|
||||
# now check price :D
|
||||
|
|
Loading…
Reference in New Issue