aboutsummaryrefslogtreecommitdiffstats
path: root/src/slskd/Program.cs
diff options
context:
space:
mode:
authorJP Dillingham <jpdillingham@gmail.com>2022-05-08 11:43:49 -0500
committerJP Dillingham <jpdillingham@gmail.com>2022-05-08 11:43:49 -0500
commita77207e83507f1444f1cfcb62ac66b4c55c0d6ce (patch)
tree7027b735494f53d0b4d8d9326f09bbacee63a4e7 /src/slskd/Program.cs
parent401a3346899c1048a901c2fb64baf82ccc13815c (diff)
downloadslskd-a77207e83507f1444f1cfcb62ac66b4c55c0d6ce.tar.gz
remove strict url enforcement
Diffstat (limited to 'src/slskd/Program.cs')
-rw-r--r--src/slskd/Program.cs8
1 files changed, 1 insertions, 7 deletions
diff --git a/src/slskd/Program.cs b/src/slskd/Program.cs
index ecf028b4..af571a4e 100644
--- a/src/slskd/Program.cs
+++ b/src/slskd/Program.cs
@@ -602,13 +602,7 @@ namespace slskd
var urlBase = OptionsAtStartup.Web.UrlBase;
urlBase = urlBase.StartsWith("/") ? urlBase : "/" + urlBase;
- // 404 if a custom urlBase is set, but the request doesn't include it.
- // this is necessary to make sure the development-time and run-time behavior
- // are consistent.
- app.EnforceUrlBase(urlBase);
-
- // use urlBase. this effectively just removes urlBase from the path, which is
- // why the enforcement behavior exists above (the actually requested path becomes ambiguous)
+ // use urlBase. this effectively just removes urlBase from the path.
// inject urlBase into any html files we serve, and rewrite links to ./static or /static to
// prepend the url base.
app.UsePathBase(urlBase);