aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Api/Playback/BaseStreamingService.cs
diff options
context:
space:
mode:
Diffstat (limited to 'MediaBrowser.Api/Playback/BaseStreamingService.cs')
-rw-r--r--MediaBrowser.Api/Playback/BaseStreamingService.cs19
1 files changed, 18 insertions, 1 deletions
diff --git a/MediaBrowser.Api/Playback/BaseStreamingService.cs b/MediaBrowser.Api/Playback/BaseStreamingService.cs
index 04b6a656d..19b339cd7 100644
--- a/MediaBrowser.Api/Playback/BaseStreamingService.cs
+++ b/MediaBrowser.Api/Playback/BaseStreamingService.cs
@@ -622,9 +622,26 @@ namespace MediaBrowser.Api.Playback
/// <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;