aboutsummaryrefslogtreecommitdiff
path: root/Emby.Server.Implementations/HttpServer
diff options
context:
space:
mode:
authorLuke <luke.pulverenti@gmail.com>2016-11-10 09:49:56 -0500
committerGitHub <noreply@github.com>2016-11-10 09:49:56 -0500
commit43f3b6097fbc5bb17f281dae123553ee52ee0a37 (patch)
tree3e6aba78db9452803edf552189e8659faf2d0b6a /Emby.Server.Implementations/HttpServer
parentb580209848e25f9de597a9797eae7a8813c4e3ab (diff)
parent9b891f2c9a4f37e2a914dc8fc5faba4e919e2b8f (diff)
Merge pull request #2279 from MediaBrowser/dev
Dev
Diffstat (limited to 'Emby.Server.Implementations/HttpServer')
-rw-r--r--Emby.Server.Implementations/HttpServer/SwaggerService.cs9
1 files changed, 5 insertions, 4 deletions
diff --git a/Emby.Server.Implementations/HttpServer/SwaggerService.cs b/Emby.Server.Implementations/HttpServer/SwaggerService.cs
index 3c181e425..d41946645 100644
--- a/Emby.Server.Implementations/HttpServer/SwaggerService.cs
+++ b/Emby.Server.Implementations/HttpServer/SwaggerService.cs
@@ -6,15 +6,16 @@ using MediaBrowser.Model.Services;
namespace Emby.Server.Implementations.HttpServer
{
- public class SwaggerService : IHasResultFactory, IService
+ public class SwaggerService : IService, IRequiresRequest
{
private readonly IServerApplicationPaths _appPaths;
private readonly IFileSystem _fileSystem;
- public SwaggerService(IServerApplicationPaths appPaths, IFileSystem fileSystem)
+ public SwaggerService(IServerApplicationPaths appPaths, IFileSystem fileSystem, IHttpResultFactory resultFactory)
{
_appPaths = appPaths;
_fileSystem = fileSystem;
+ _resultFactory = resultFactory;
}
/// <summary>
@@ -28,14 +29,14 @@ namespace Emby.Server.Implementations.HttpServer
var requestedFile = Path.Combine(swaggerDirectory, request.ResourceName.Replace('/', _fileSystem.DirectorySeparatorChar));
- return ResultFactory.GetStaticFileResult(Request, requestedFile).Result;
+ return _resultFactory.GetStaticFileResult(Request, requestedFile).Result;
}
/// <summary>
/// Gets or sets the result factory.
/// </summary>
/// <value>The result factory.</value>
- public IHttpResultFactory ResultFactory { get; set; }
+ private readonly IHttpResultFactory _resultFactory;
/// <summary>
/// Gets or sets the request context.