mirror of
https://github.com/jellyfin/jellyfin.git
synced 2024-07-05 21:33:02 +02:00
update playlist creation
This commit is contained in:
parent
7a77aa42c5
commit
82c65f3788
|
@ -100,7 +100,7 @@ namespace Emby.Server.Implementations.Playlists
|
||||||
|
|
||||||
if (string.IsNullOrWhiteSpace(options.MediaType))
|
if (string.IsNullOrWhiteSpace(options.MediaType))
|
||||||
{
|
{
|
||||||
throw new ArgumentException("A playlist media type is required.");
|
options.MediaType = "Audio";
|
||||||
}
|
}
|
||||||
|
|
||||||
var user = _userManager.GetUserById(options.UserId);
|
var user = _userManager.GetUserById(options.UserId);
|
||||||
|
|
|
@ -964,13 +964,14 @@ namespace MediaBrowser.XbmcMetadata.Parsers
|
||||||
}
|
}
|
||||||
|
|
||||||
default:
|
default:
|
||||||
var providerId = reader.Name;
|
string readerName = reader.Name;
|
||||||
if (_validProviderIds.ContainsKey(providerId))
|
string providerIdValue;
|
||||||
|
if (_validProviderIds.TryGetValue(readerName, out providerIdValue))
|
||||||
{
|
{
|
||||||
var id = reader.ReadElementContentAsString();
|
var id = reader.ReadElementContentAsString();
|
||||||
if (!string.IsNullOrWhiteSpace(id))
|
if (!string.IsNullOrWhiteSpace(id))
|
||||||
{
|
{
|
||||||
item.SetProviderId(_validProviderIds[providerId], id);
|
item.SetProviderId(providerIdValue, id);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in a new issue