mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-03-18 08:06:35 +00:00
start a dashboard folder
This commit is contained in:
@@ -428,8 +428,24 @@ namespace MediaBrowser.Server.Implementations.HttpServer
|
||||
|
||||
if (string.Equals(localPath, "/mediabrowser/", StringComparison.OrdinalIgnoreCase) ||
|
||||
string.Equals(localPath, "/mediabrowser", StringComparison.OrdinalIgnoreCase) ||
|
||||
localPath.IndexOf("mediabrowser/web", StringComparison.OrdinalIgnoreCase) != -1 ||
|
||||
localPath.IndexOf("dashboard/", StringComparison.OrdinalIgnoreCase) != -1)
|
||||
localPath.IndexOf("mediabrowser/web", StringComparison.OrdinalIgnoreCase) != -1)
|
||||
{
|
||||
httpRes.StatusCode = 200;
|
||||
httpRes.ContentType = "text/html";
|
||||
var newUrl = urlString.Replace("mediabrowser", "emby", StringComparison.OrdinalIgnoreCase)
|
||||
.Replace("/dashboard/", "/web/", StringComparison.OrdinalIgnoreCase);
|
||||
|
||||
if (!string.Equals(newUrl, urlString, StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
httpRes.Write("<!doctype html><html><head><title>Emby</title></head><body>Please update your Emby bookmark to <a href=\"" + newUrl + "\">" + newUrl + "</a></body></html>");
|
||||
|
||||
httpRes.Close();
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if (localPath.IndexOf("dashboard/", StringComparison.OrdinalIgnoreCase) != -1 &&
|
||||
localPath.IndexOf("web/dashboard", StringComparison.OrdinalIgnoreCase) == -1)
|
||||
{
|
||||
httpRes.StatusCode = 200;
|
||||
httpRes.ContentType = "text/html";
|
||||
|
||||
Reference in New Issue
Block a user