diff options
| author | simon <admin@nyalindee.com> | 2014-01-13 12:32:10 +1100 |
|---|---|---|
| committer | simon <admin@nyalindee.com> | 2014-01-13 12:32:10 +1100 |
| commit | 37aab84b2af0e86eff668b888aa577d74b55a687 (patch) | |
| tree | 5120180925cb3617b05c7920d654d890083d9f40 /MediaBrowser.Server.Implementations/HttpServer/HttpResultFactory.cs | |
| parent | f89deb346a405e1d431841218a51f64acf743a0e (diff) | |
| parent | e4f5a3f005a240b013194d6a54edce29fef91e11 (diff) | |
Merge branch 'master' of https://github.com/MediaBrowser/MediaBrowser
Diffstat (limited to 'MediaBrowser.Server.Implementations/HttpServer/HttpResultFactory.cs')
| -rw-r--r-- | MediaBrowser.Server.Implementations/HttpServer/HttpResultFactory.cs | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/MediaBrowser.Server.Implementations/HttpServer/HttpResultFactory.cs b/MediaBrowser.Server.Implementations/HttpServer/HttpResultFactory.cs index 2419320a5..9359261c5 100644 --- a/MediaBrowser.Server.Implementations/HttpServer/HttpResultFactory.cs +++ b/MediaBrowser.Server.Implementations/HttpServer/HttpResultFactory.cs @@ -360,19 +360,11 @@ namespace MediaBrowser.Server.Implementations.HttpServer var compress = ShouldCompressResponse(requestContext, contentType); - var hasOptions = GetStaticResult(requestContext, responseHeaders, contentType, factoryFn, compress, isHeadRequest); + var hasOptions = GetStaticResult(requestContext, responseHeaders, contentType, factoryFn, compress, isHeadRequest).Result; - return GetStaticResultTask(hasOptions, responseHeaders); - } - - private async Task<object> GetStaticResultTask(Task<IHasOptions> optionsTask, - IEnumerable<KeyValuePair<string, string>> responseHeaders) - { - var options = await optionsTask.ConfigureAwait(false); - - AddResponseHeaders(options, responseHeaders); + AddResponseHeaders(hasOptions, responseHeaders); - return options; + return hasOptions; } /// <summary> @@ -670,4 +662,4 @@ namespace MediaBrowser.Server.Implementations.HttpServer throw error; } } -} +}
\ No newline at end of file |
