|
|
|
@ -141,6 +141,8 @@ namespace NzbDrone.Core.MediaFiles.EpisodeImport.Manual
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private ManualImportItem ProcessFile(string rootFolder, string baseFolder, string file, string downloadId, Series series = null)
|
|
|
|
|
{
|
|
|
|
|
try
|
|
|
|
|
{
|
|
|
|
|
DownloadClientItem downloadClientItem = null;
|
|
|
|
|
var relativeFile = baseFolder.GetRelativePath(file);
|
|
|
|
@ -184,15 +186,22 @@ namespace NzbDrone.Core.MediaFiles.EpisodeImport.Manual
|
|
|
|
|
localEpisode.Language = LanguageParser.ParseLanguage(file);
|
|
|
|
|
localEpisode.Size = _diskProvider.GetFileSize(file);
|
|
|
|
|
|
|
|
|
|
return MapItem(new ImportDecision(localEpisode, new Rejection("Unknown Series")), rootFolder, downloadId, null);
|
|
|
|
|
return MapItem(new ImportDecision(localEpisode, new Rejection("Unknown Series")), rootFolder,
|
|
|
|
|
downloadId, null);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var importDecisions = _importDecisionMaker.GetImportDecisions(new List<string> {file}, series, downloadClientItem, null, SceneSource(series, baseFolder));
|
|
|
|
|
var importDecisions = _importDecisionMaker.GetImportDecisions(new List<string> {file}, series,
|
|
|
|
|
downloadClientItem, null, SceneSource(series, baseFolder));
|
|
|
|
|
|
|
|
|
|
if (importDecisions.Any())
|
|
|
|
|
{
|
|
|
|
|
return MapItem(importDecisions.First(), rootFolder, downloadId, null);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
catch (Exception ex)
|
|
|
|
|
{
|
|
|
|
|
_logger.Warn(ex, "Failed to process file: {0}", file);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return new ManualImportItem
|
|
|
|
|
{
|
|
|
|
|