more updates for api docs

This commit is contained in:
LukePulverenti
2013-03-08 16:06:02 -05:00
parent 9ffb44244c
commit 34cc4eee9d
4 changed files with 37 additions and 35 deletions

View File

@@ -83,7 +83,7 @@ namespace MediaBrowser.Server.Implementations.HttpServer
var key = cacheKey.ToString("N");
var result = PreProcessCachedResult(cacheKey, key, lastDateModified, cacheDuration, string.Empty);
var result = PreProcessCachedResult(cacheKey, key, lastDateModified, cacheDuration);
if (result != null)
{
@@ -117,9 +117,11 @@ namespace MediaBrowser.Server.Implementations.HttpServer
throw new ArgumentNullException("factoryFn");
}
Response.ContentType = contentType;
var key = cacheKey.ToString("N");
var result = PreProcessCachedResult(cacheKey, key, lastDateModified, cacheDuration, contentType);
var result = PreProcessCachedResult(cacheKey, key, lastDateModified, cacheDuration);
if (result != null)
{
@@ -183,7 +185,9 @@ namespace MediaBrowser.Server.Implementations.HttpServer
var key = cacheKey.ToString("N");
var result = PreProcessCachedResult(cacheKey, key, lastDateModified, cacheDuration, contentType);
Response.ContentType = contentType;
var result = PreProcessCachedResult(cacheKey, key, lastDateModified, cacheDuration);
if (result != null)
{
@@ -278,9 +282,8 @@ namespace MediaBrowser.Server.Implementations.HttpServer
/// <param name="cacheKeyString">The cache key string.</param>
/// <param name="lastDateModified">The last date modified.</param>
/// <param name="cacheDuration">Duration of the cache.</param>
/// <param name="contentType">Type of the content.</param>
/// <returns>System.Object.</returns>
private object PreProcessCachedResult(Guid cacheKey, string cacheKeyString, DateTime? lastDateModified, TimeSpan? cacheDuration, string contentType)
private object PreProcessCachedResult(Guid cacheKey, string cacheKeyString, DateTime? lastDateModified, TimeSpan? cacheDuration)
{
Response.AddHeader("ETag", cacheKeyString);
@@ -290,11 +293,6 @@ namespace MediaBrowser.Server.Implementations.HttpServer
AddExpiresHeader(cacheKeyString, cacheDuration);
//ctx.Response.SendChunked = false;
if (!string.IsNullOrEmpty(contentType))
{
Response.ContentType = contentType;
}
Response.StatusCode = 304;
return new byte[]{};