mirror of
https://github.com/Readarr/Readarr
synced 2026-05-08 12:42:51 +02:00
Fixed: Don't try to read audio tags from a book file
This commit is contained in:
parent
c817d6c0d8
commit
341d64ebf7
1 changed files with 6 additions and 4 deletions
|
|
@ -1,5 +1,7 @@
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.IO;
|
||||||
|
using System.IO.Abstractions;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using NLog;
|
using NLog;
|
||||||
using NzbDrone.Common.Extensions;
|
using NzbDrone.Common.Extensions;
|
||||||
|
|
@ -17,19 +19,19 @@ public interface IIdentificationService
|
||||||
public class IdentificationService : IIdentificationService
|
public class IdentificationService : IIdentificationService
|
||||||
{
|
{
|
||||||
private readonly ITrackGroupingService _trackGroupingService;
|
private readonly ITrackGroupingService _trackGroupingService;
|
||||||
private readonly IAudioTagService _audioTagService;
|
private readonly IMetadataTagService _metadataTagService;
|
||||||
private readonly IAugmentingService _augmentingService;
|
private readonly IAugmentingService _augmentingService;
|
||||||
private readonly ICandidateService _candidateService;
|
private readonly ICandidateService _candidateService;
|
||||||
private readonly Logger _logger;
|
private readonly Logger _logger;
|
||||||
|
|
||||||
public IdentificationService(ITrackGroupingService trackGroupingService,
|
public IdentificationService(ITrackGroupingService trackGroupingService,
|
||||||
IAudioTagService audioTagService,
|
IMetadataTagService metadataTagService,
|
||||||
IAugmentingService augmentingService,
|
IAugmentingService augmentingService,
|
||||||
ICandidateService candidateService,
|
ICandidateService candidateService,
|
||||||
Logger logger)
|
Logger logger)
|
||||||
{
|
{
|
||||||
_trackGroupingService = trackGroupingService;
|
_trackGroupingService = trackGroupingService;
|
||||||
_audioTagService = audioTagService;
|
_metadataTagService = metadataTagService;
|
||||||
_augmentingService = augmentingService;
|
_augmentingService = augmentingService;
|
||||||
_candidateService = candidateService;
|
_candidateService = candidateService;
|
||||||
_logger = logger;
|
_logger = logger;
|
||||||
|
|
@ -101,7 +103,7 @@ private List<LocalBook> ToLocalTrack(IEnumerable<BookFile> trackfiles, LocalEdit
|
||||||
Path = x.Path,
|
Path = x.Path,
|
||||||
Size = x.Size,
|
Size = x.Size,
|
||||||
Modified = x.Modified,
|
Modified = x.Modified,
|
||||||
FileTrackInfo = _audioTagService.ReadTags(x.Path),
|
FileTrackInfo = _metadataTagService.ReadTags((FileInfoBase)new FileInfo(x.Path)),
|
||||||
ExistingFile = true,
|
ExistingFile = true,
|
||||||
AdditionalFile = true,
|
AdditionalFile = true,
|
||||||
Quality = x.Quality
|
Quality = x.Quality
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue