You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
28 lines
686 B
28 lines
686 B
using System;
|
|
using NzbDrone.Core.Movies;
|
|
using NzbDrone.Core.Parser.Model;
|
|
|
|
namespace NzbDrone.Core.Parser.Augmenters
|
|
{
|
|
public class AugmentWithOriginalLanguage : IAugmentParsedMovieInfo
|
|
{
|
|
public Type HelperType
|
|
{
|
|
get
|
|
{
|
|
return typeof(Movie);
|
|
}
|
|
}
|
|
|
|
public ParsedMovieInfo AugmentMovieInfo(ParsedMovieInfo movieInfo, object helper)
|
|
{
|
|
if (helper is Movie movie && movie?.OriginalLanguage != null && movieInfo != null)
|
|
{
|
|
movieInfo.ExtraInfo["OriginalLanguage"] = movie.OriginalLanguage;
|
|
}
|
|
|
|
return movieInfo;
|
|
}
|
|
}
|
|
}
|