aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Api/ApiService.cs
diff options
context:
space:
mode:
Diffstat (limited to 'MediaBrowser.Api/ApiService.cs')
-rw-r--r--MediaBrowser.Api/ApiService.cs6
1 files changed, 6 insertions, 0 deletions
diff --git a/MediaBrowser.Api/ApiService.cs b/MediaBrowser.Api/ApiService.cs
index ab12a350f..6b3c00ee2 100644
--- a/MediaBrowser.Api/ApiService.cs
+++ b/MediaBrowser.Api/ApiService.cs
@@ -5,6 +5,7 @@ using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
+using System.Net;
namespace MediaBrowser.Api
{
@@ -374,5 +375,10 @@ namespace MediaBrowser.Api
LastLoginDate = user.LastLoginDate
};
}
+
+ public static bool IsApiUrlMatch(string url, HttpListenerRequest request)
+ {
+ return request.Url.LocalPath.EndsWith(url, StringComparison.OrdinalIgnoreCase);
+ }
}
}