mirror of
https://github.com/jellyfin/jellyfin.git
synced 2024-11-16 02:18:54 -07:00
Remove dead code
This commit is contained in:
parent
a332092769
commit
157a86d0f1
@ -11,8 +11,6 @@ namespace Emby.Server.Implementations.Services
|
|||||||
{
|
{
|
||||||
public class ServiceHandler
|
public class ServiceHandler
|
||||||
{
|
{
|
||||||
private readonly ServiceController _serviceController;
|
|
||||||
|
|
||||||
public RestPath RestPath { get; }
|
public RestPath RestPath { get; }
|
||||||
|
|
||||||
public string ResponseContentType { get; }
|
public string ResponseContentType { get; }
|
||||||
@ -28,22 +26,12 @@ namespace Emby.Server.Implementations.Services
|
|||||||
if (!string.IsNullOrEmpty(contentType) && httpReq.ContentLength > 0)
|
if (!string.IsNullOrEmpty(contentType) && httpReq.ContentLength > 0)
|
||||||
{
|
{
|
||||||
var deserializer = RequestHelper.GetRequestReader(host, contentType);
|
var deserializer = RequestHelper.GetRequestReader(host, contentType);
|
||||||
if (deserializer != null)
|
return deserializer?.Invoke(requestType, httpReq.InputStream);
|
||||||
{
|
|
||||||
return deserializer(requestType, httpReq.InputStream);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return Task.FromResult(host.CreateInstance(requestType));
|
return Task.FromResult(host.CreateInstance(requestType));
|
||||||
}
|
}
|
||||||
|
|
||||||
public RestPath FindMatchingRestPath(string httpMethod, string pathInfo, out string contentType)
|
|
||||||
{
|
|
||||||
pathInfo = GetSanitizedPathInfo(pathInfo, out contentType);
|
|
||||||
|
|
||||||
return _serviceController.GetRestPathForRequest(httpMethod, pathInfo);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static string GetSanitizedPathInfo(string pathInfo, out string contentType)
|
public static string GetSanitizedPathInfo(string pathInfo, out string contentType)
|
||||||
{
|
{
|
||||||
contentType = null;
|
contentType = null;
|
||||||
|
Loading…
Reference in New Issue
Block a user