mirror of
https://github.com/Sonarr/Sonarr.git
synced 2026-04-19 21:46:43 -04:00
26 lines
774 B
C#
26 lines
774 B
C#
using NzbDrone.Core.Extras.Metadata;
|
|
|
|
namespace NzbDrone.Api.Metadata
|
|
{
|
|
public class MetadataModule : ProviderModuleBase<MetadataResource, IMetadata, MetadataDefinition>
|
|
{
|
|
public MetadataModule(IMetadataFactory metadataFactory)
|
|
: base(metadataFactory, "metadata")
|
|
{
|
|
}
|
|
|
|
protected override void MapToResource(MetadataResource resource, MetadataDefinition definition)
|
|
{
|
|
base.MapToResource(resource, definition);
|
|
|
|
resource.Enable = definition.Enable;
|
|
}
|
|
|
|
protected override void MapToModel(MetadataDefinition definition, MetadataResource resource)
|
|
{
|
|
base.MapToModel(definition, resource);
|
|
|
|
definition.Enable = resource.Enable;
|
|
}
|
|
}
|
|
} |