Skip to content

Commit

Permalink
make deezer readable default to false
Browse files Browse the repository at this point in the history
  • Loading branch information
topi314 committed Jan 29, 2025
1 parent d9dcbc8 commit 5f503a8
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,7 @@ private List<AudioTrack> parseTracks(JsonBrowser json, boolean preview) {
if (!track.get("type").text().equals("track")) {
continue;
}
if (!track.get("readable").asBoolean(true)) {
if (!track.get("readable").asBoolean(false)) {
log.warn("Skipping track {} by {} because it is not readable. Available countries: {}", track.get("title").text(), track.get("artist").get("name").text(), track.get("available_countries").text());
continue;
}
Expand All @@ -309,7 +309,7 @@ private List<AudioTrack> parseTracks(JsonBrowser json, boolean preview) {
}

private AudioTrack parseTrack(JsonBrowser json, boolean preview) {
if (!json.get("readable").asBoolean(true)) {
if (!json.get("readable").asBoolean(false)) {
throw new FriendlyException("This track is not readable. Available countries: " + json.get("available_countries").text(),
FriendlyException.Severity.COMMON, null);
}
Expand Down

0 comments on commit 5f503a8

Please sign in to comment.