mirror of
https://github.com/pockethost/pockethost.git
synced 2025-11-23 22:15:49 +00:00
fix: update MOTHERSHIP_URL formatting to include subdomain and trim path segments
This commit is contained in:
parent
ef6c9e1f57
commit
1e02cb466a
5
.changeset/happy-poets-wait.md
Normal file
5
.changeset/happy-poets-wait.md
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
---
|
||||||
|
'pockethost': patch
|
||||||
|
---
|
||||||
|
|
||||||
|
update MOTHERSHIP_URL formatting to include subdomain and trim path segments
|
||||||
@ -196,9 +196,9 @@ export const MOTHERSHIP_URL = (...path: string[]) =>
|
|||||||
[
|
[
|
||||||
env
|
env
|
||||||
.get('MOTHERSHIP_URL')
|
.get('MOTHERSHIP_URL')
|
||||||
.default(`${HTTP_PROTOCOL()}://${MOTHERSHIP_NAME()}:${APEX_DOMAIN()}`)
|
.default(`${HTTP_PROTOCOL()}://${MOTHERSHIP_NAME()}.${APEX_DOMAIN()}`)
|
||||||
.asString(),
|
.asString(),
|
||||||
path.join('/'),
|
...path.map((p) => p.trim().replace(/^\/+|\/+$/g, '')),
|
||||||
]
|
]
|
||||||
.filter(Boolean)
|
.filter(Boolean)
|
||||||
.join('/')
|
.join('/')
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user