Fixed MediaCover endpoint.

pull/2/head
Taloth Saldono 7 years ago committed by Leonardo Galli
parent 72a12a73af
commit efbb587290

@ -52,6 +52,7 @@ namespace NzbDrone.Api.Frontend.Mappers
resourceUrl = resourceUrl.ToLowerInvariant(); resourceUrl = resourceUrl.ToLowerInvariant();
return !resourceUrl.StartsWith("/content") && return !resourceUrl.StartsWith("/content") &&
!resourceUrl.StartsWith("/mediacover") &&
!resourceUrl.Contains(".") && !resourceUrl.Contains(".") &&
!resourceUrl.StartsWith("/login"); !resourceUrl.StartsWith("/login");
} }

@ -1,3 +1,4 @@
using System;
using System.IO; using System.IO;
using System.Text.RegularExpressions; using System.Text.RegularExpressions;
using NLog; using NLog;
@ -42,7 +43,7 @@ namespace NzbDrone.Api.Frontend.Mappers
public override bool CanHandle(string resourceUrl) public override bool CanHandle(string resourceUrl)
{ {
return resourceUrl.StartsWith("/MediaCover"); return resourceUrl.StartsWith("/MediaCover", StringComparison.InvariantCultureIgnoreCase);
} }
} }
} }
Loading…
Cancel
Save