mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-06-16 04:30:24 +01:00
support static trailer streaming
This commit is contained in:
@@ -621,10 +621,27 @@ namespace MediaBrowser.Api.Playback
|
||||
/// <param name="item">The item.</param>
|
||||
/// <returns>System.String.</returns>
|
||||
protected string GetUserAgentParam(BaseItem item)
|
||||
{
|
||||
var useragent = GetUserAgent(item);
|
||||
|
||||
if (!string.IsNullOrEmpty(useragent))
|
||||
{
|
||||
return "-user-agent \"" + useragent + "\"";
|
||||
}
|
||||
|
||||
return string.Empty;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets the user agent.
|
||||
/// </summary>
|
||||
/// <param name="item">The item.</param>
|
||||
/// <returns>System.String.</returns>
|
||||
protected string GetUserAgent(BaseItem item)
|
||||
{
|
||||
if (item.Path.IndexOf("apple.com", StringComparison.OrdinalIgnoreCase) != -1)
|
||||
{
|
||||
return "-user-agent \"QuickTime/7.6.2\"";
|
||||
return "QuickTime/7.6.2";
|
||||
}
|
||||
|
||||
return string.Empty;
|
||||
|
||||
Reference in New Issue
Block a user