From cce735b243464c6ab9df87b28e4603e5cdb70c59 Mon Sep 17 00:00:00 2001 From: Blake Date: Mon, 28 Nov 2022 17:17:10 -0600 Subject: [PATCH] Bug fix in Audio.sh Looks like some copy-pasta. Prior to this fix I would see lots of errors in the Audio.log such as: `jq: error (at :418): Cannot index string with string "qualityCutoffNotMet"`. With the fix the cutoff related code does what it is supposed to. --- root/scripts/Audio.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/root/scripts/Audio.sh b/root/scripts/Audio.sh index 436f0dd..f0d8249 100644 --- a/root/scripts/Audio.sh +++ b/root/scripts/Audio.sh @@ -1808,7 +1808,7 @@ CheckLidarrBeforeImport () { if [ "$wantedAlbumListSource" == "cutoff" ]; then checkLidarrAlbumFiles="$(curl -s "$lidarrUrl/api/v1/trackFile?albumId=$1?apikey=${lidarrApiKey}")" - checkLidarrAlbumQualityCutoffNotMet=$(echo "$checkLidarrAlbumData" | jq -r ".[].qualityCutoffNotMet") + checkLidarrAlbumQualityCutoffNotMet=$(echo "$checkLidarrAlbumFiles" | jq -r ".[].qualityCutoffNotMet") if echo "$checkLidarrAlbumQualityCutoffNotMet" | grep "true" | read; then log "$page :: $wantedAlbumListSource :: $processNumber of $wantedListAlbumTotal :: $lidarrArtistName :: $lidarrAlbumTitle :: $lidarrAlbumType :: Already Imported Album (CutOff - $checkLidarrAlbumQualityCutoffNotMet), skipping..." alreadyImported=true