aboutsummaryrefslogtreecommitdiff
path: root/apps/proxy
diff options
context:
space:
mode:
authorFuwn <[email protected]>2026-04-18 08:46:53 +0000
committerFuwn <[email protected]>2026-04-18 08:46:53 +0000
commit5b95492f0ac2f0b5afd3f212c3d568c9b7d61d97 (patch)
treebabb7d269c6c79c6067f08da9f37323477f5fe09 /apps/proxy
parentbuild(dev): use portless for named .localhost dev URL (diff)
downloaddue.moe-5b95492f0ac2f0b5afd3f212c3d568c9b7d61d97.tar.xz
due.moe-5b95492f0ac2f0b5afd3f212c3d568c9b7d61d97.zip
fix(dev): route portless .localhost URL through app origin and proxy CORS
Diffstat (limited to 'apps/proxy')
-rw-r--r--apps/proxy/src/index.js1
1 files changed, 1 insertions, 0 deletions
diff --git a/apps/proxy/src/index.js b/apps/proxy/src/index.js
index 592899c0..fa2503b5 100644
--- a/apps/proxy/src/index.js
+++ b/apps/proxy/src/index.js
@@ -18,6 +18,7 @@ const isPrivateHostname = (hostname) =>
hostname === "localhost" ||
hostname === "127.0.0.1" ||
hostname.endsWith(".local") ||
+ hostname.endsWith(".localhost") ||
/^10\./.test(hostname) ||
/^192\.168\./.test(hostname) ||
/^172\.(1[6-9]|2\d|3[0-1])\./.test(hostname);