Skip to content

Commit

Permalink
Merge pull request #1178 from darrell-k/include-track-artists
Browse files Browse the repository at this point in the history
return all roles not undef when all roles requested
  • Loading branch information
michaelherger authored Oct 14, 2024
2 parents e6c043d + 3dba1ac commit 55154c0
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions Slim/Schema.pm
Original file line number Diff line number Diff line change
Expand Up @@ -2347,7 +2347,7 @@ sub artistOnlyRoles {

# And if the user has asked for ALL, give them it.
if ($roles{'ALL'}) {
return undef;
return [ Slim::Schema::Contributor->contributorRoleIds ];
}

# Loop through each pref to see if the user wants to show that contributor role.
Expand All @@ -2359,13 +2359,8 @@ sub artistOnlyRoles {
}
}

# If we're using all roles, don't bother with the constraint.
if (scalar keys %roles != Slim::Schema::Contributor->totalContributorRoles) {

return [ sort map { Slim::Schema::Contributor->typeToRole($_) } keys %roles ];
}
return [ sort map { Slim::Schema::Contributor->typeToRole($_) } keys %roles ];

return undef;
}

sub registerRatingImplementation {
Expand Down

0 comments on commit 55154c0

Please sign in to comment.