mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-04-22 10:04:44 +01:00
Use Microsoft.Extensions.Logging abstraction
This commit is contained in:
@@ -4,7 +4,7 @@ using System.IO;
|
||||
using System.Linq;
|
||||
using System.Reflection;
|
||||
using System.Text;
|
||||
using MediaBrowser.Model.Logging;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using MediaBrowser.Model.Extensions;
|
||||
|
||||
namespace Emby.Server.Implementations.Services
|
||||
@@ -354,25 +354,25 @@ namespace Emby.Server.Implementations.Services
|
||||
|
||||
if (withPathInfoParts.Length != this.PathComponentsCount && !this.IsWildCardPath)
|
||||
{
|
||||
//logger.Info("withPathInfoParts mismatch for {0} for {1}", httpMethod, string.Join("/", withPathInfoParts));
|
||||
//logger.LogInformation("withPathInfoParts mismatch for {0} for {1}", httpMethod, string.Join("/", withPathInfoParts));
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!Verbs.Contains(httpMethod, StringComparer.OrdinalIgnoreCase))
|
||||
{
|
||||
//logger.Info("allowsAllVerbs mismatch for {0} for {1} allowedverbs {2}", httpMethod, string.Join("/", withPathInfoParts), this.allowedVerbs);
|
||||
//logger.LogInformation("allowsAllVerbs mismatch for {0} for {1} allowedverbs {2}", httpMethod, string.Join("/", withPathInfoParts), this.allowedVerbs);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!ExplodeComponents(ref withPathInfoParts))
|
||||
{
|
||||
//logger.Info("ExplodeComponents mismatch for {0} for {1}", httpMethod, string.Join("/", withPathInfoParts));
|
||||
//logger.LogInformation("ExplodeComponents mismatch for {0} for {1}", httpMethod, string.Join("/", withPathInfoParts));
|
||||
return false;
|
||||
}
|
||||
|
||||
if (this.TotalComponentsCount != withPathInfoParts.Length && !this.IsWildCardPath)
|
||||
{
|
||||
//logger.Info("TotalComponentsCount mismatch for {0} for {1}", httpMethod, string.Join("/", withPathInfoParts));
|
||||
//logger.LogInformation("TotalComponentsCount mismatch for {0} for {1}", httpMethod, string.Join("/", withPathInfoParts));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -393,7 +393,7 @@ namespace Emby.Server.Implementations.Services
|
||||
// Ensure there are still enough parts left to match the remainder
|
||||
if ((withPathInfoParts.Length - pathIx) < (this.TotalComponentsCount - i - 1))
|
||||
{
|
||||
//logger.Info("withPathInfoParts length mismatch for {0} for {1}", httpMethod, string.Join("/", withPathInfoParts));
|
||||
//logger.LogInformation("withPathInfoParts length mismatch for {0} for {1}", httpMethod, string.Join("/", withPathInfoParts));
|
||||
return false;
|
||||
}
|
||||
}
|
||||
@@ -416,7 +416,7 @@ namespace Emby.Server.Implementations.Services
|
||||
|
||||
if (withPathInfoParts.Length <= pathIx || !LiteralsEqual(withPathInfoParts[pathIx], literalToMatch))
|
||||
{
|
||||
//logger.Info("withPathInfoParts2 length mismatch for {0} for {1}. not equals: {2} != {3}.", httpMethod, string.Join("/", withPathInfoParts), withPathInfoParts[pathIx], literalToMatch);
|
||||
//logger.LogInformation("withPathInfoParts2 length mismatch for {0} for {1}. not equals: {2} != {3}.", httpMethod, string.Join("/", withPathInfoParts), withPathInfoParts[pathIx], literalToMatch);
|
||||
return false;
|
||||
}
|
||||
pathIx++;
|
||||
|
||||
Reference in New Issue
Block a user