Fixed: Tag deletion via api if tag is still in use

This commit is contained in:
Taloth Saldono
2019-06-15 20:11:50 +02:00
committed by Qstick
parent d41ae7b172
commit a99ee41f38
4 changed files with 58 additions and 11 deletions
@@ -0,0 +1,20 @@
using System;
using NzbDrone.Common.Exceptions;
namespace NzbDrone.Core.Datastore
{
public class ModelConflictException : NzbDroneException
{
public ModelConflictException(Type modelType, int modelId)
: base("{0} with ID {1} cannot be modified", modelType.Name, modelId)
{
}
public ModelConflictException(Type modelType, int modelId, string message)
: base("{0} with ID {1} {2}", modelType.Name, modelId, message)
{
}
}
}