mirror of
https://github.com/jellyfin/jellyfin.git
synced 2025-07-09 03:04:24 -04:00
fixes #915 - Reading genre/studio/country from nfo by MediaBrowser not handled like XBMC
This commit is contained in:
parent
f7041ccb4a
commit
09bffa1b56
@ -343,7 +343,14 @@ namespace MediaBrowser.XbmcMetadata.Parsers
|
|||||||
{
|
{
|
||||||
if (!string.IsNullOrWhiteSpace(val))
|
if (!string.IsNullOrWhiteSpace(val))
|
||||||
{
|
{
|
||||||
hasProductionLocations.AddProductionLocation(val);
|
var parts = val.Split('/')
|
||||||
|
.Select(i => i.Trim())
|
||||||
|
.Where(i => !string.IsNullOrWhiteSpace(i));
|
||||||
|
|
||||||
|
foreach (var p in parts)
|
||||||
|
{
|
||||||
|
hasProductionLocations.AddProductionLocation(p);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@ -426,7 +433,14 @@ namespace MediaBrowser.XbmcMetadata.Parsers
|
|||||||
|
|
||||||
if (!string.IsNullOrWhiteSpace(val))
|
if (!string.IsNullOrWhiteSpace(val))
|
||||||
{
|
{
|
||||||
item.AddStudio(val);
|
var parts = val.Split('/')
|
||||||
|
.Select(i => i.Trim())
|
||||||
|
.Where(i => !string.IsNullOrWhiteSpace(i));
|
||||||
|
|
||||||
|
foreach (var p in parts)
|
||||||
|
{
|
||||||
|
item.AddStudio(p);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -730,9 +744,17 @@ namespace MediaBrowser.XbmcMetadata.Parsers
|
|||||||
case "genre":
|
case "genre":
|
||||||
{
|
{
|
||||||
var val = reader.ReadElementContentAsString();
|
var val = reader.ReadElementContentAsString();
|
||||||
|
|
||||||
if (!string.IsNullOrWhiteSpace(val))
|
if (!string.IsNullOrWhiteSpace(val))
|
||||||
{
|
{
|
||||||
item.AddGenre(val);
|
var parts = val.Split('/')
|
||||||
|
.Select(i => i.Trim())
|
||||||
|
.Where(i => !string.IsNullOrWhiteSpace(i));
|
||||||
|
|
||||||
|
foreach (var p in parts)
|
||||||
|
{
|
||||||
|
item.AddGenre(p);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user