Add Director to role mapper for TMDb

pull/3089/head
MrTimscampi 5 years ago
parent 9137069f6d
commit d5ad53e4bb

@ -313,7 +313,13 @@ namespace MediaBrowser.Providers.Tmdb.TV
{
foreach (var actor in seriesInfo.Credits.Cast.OrderBy(a => a.Order))
{
var personInfo = new PersonInfo {Name = actor.Name.Trim(), Role = actor.Character, Type = PersonType.Actor, SortOrder = actor.Order};
var personInfo = new PersonInfo
{
Name = actor.Name.Trim(),
Role = actor.Character,
Type = PersonType.Actor,
SortOrder = actor.Order
};
if (!string.IsNullOrWhiteSpace(actor.Profile_Path))
{

@ -14,6 +14,12 @@ namespace MediaBrowser.Providers.Tmdb
public static string MapCrewToPersonType(Crew crew)
{
if (crew.Department.Equals("production", StringComparison.InvariantCultureIgnoreCase)
&& crew.Job.IndexOf("director", StringComparison.InvariantCultureIgnoreCase) != -1)
{
return PersonType.Director;
}
if (crew.Department.Equals("production", StringComparison.InvariantCultureIgnoreCase)
&& crew.Job.IndexOf("producer", StringComparison.InvariantCultureIgnoreCase) != -1)
{

Loading…
Cancel
Save