mirror of
https://github.com/jellyfin/jellyfin
synced 2024-07-21 09:54:24 +00:00
Fixed bitrate null handling
This commit is contained in:
parent
24d2c441b3
commit
13e5b03694
|
@ -49,7 +49,12 @@ namespace MediaBrowser.Api.HttpHandlers
|
|||
{
|
||||
int index = AudioFormats.ToList().IndexOf(audioFormat);
|
||||
|
||||
return AudioBitRates.ElementAtOrDefault(index);
|
||||
if (!AudioBitRates.Any())
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
return AudioBitRates.ElementAt(index);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
|
Loading…
Reference in a new issue