mirror of
https://github.com/Readarr/Readarr.git
synced 2026-04-22 22:14:44 -04:00
Improve error message when deleting a profile that is in use
This commit is contained in:
@@ -44,7 +44,8 @@ namespace NzbDrone.Core.Profiles.Metadata
|
||||
{
|
||||
if (_artistService.GetAllArtists().Any(c => c.MetadataProfileId == id))
|
||||
{
|
||||
throw new MetadataProfileInUseException(id);
|
||||
var profile = _profileRepository.Get(id);
|
||||
throw new MetadataProfileInUseException(profile.Name);
|
||||
}
|
||||
|
||||
_profileRepository.Delete(id);
|
||||
|
||||
Reference in New Issue
Block a user