From 885efb526e646f36b4b391c636a5a1fa8a4e537e Mon Sep 17 00:00:00 2001 From: Jens Langhammer Date: Fri, 21 Jan 2022 13:51:34 +0100 Subject: [PATCH] web/admin: also set embedded outpost host when it doesn't include scheme Signed-off-by: Jens Langhammer --- web/src/pages/admin-overview/cards/SystemStatusCard.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/web/src/pages/admin-overview/cards/SystemStatusCard.ts b/web/src/pages/admin-overview/cards/SystemStatusCard.ts index 5413e1f1f..7649bc8fd 100644 --- a/web/src/pages/admin-overview/cards/SystemStatusCard.ts +++ b/web/src/pages/admin-overview/cards/SystemStatusCard.ts @@ -17,8 +17,10 @@ export class SystemStatusCard extends AdminStatusCard { async getPrimaryValue(): Promise { this.now = new Date(); let status = await new AdminApi(DEFAULT_CONFIG).adminSystemRetrieve(); - if (status.embeddedOutpostHost === "") { + if (status.embeddedOutpostHost === "" || !status.embeddedOutpostHost.includes("http")) { // First install, ensure the embedded outpost host is set + // also run when outpost host does not contain http + // (yes it's called host and requires a URL, i know) await this.setOutpostHost(); status = await new AdminApi(DEFAULT_CONFIG).adminSystemRetrieve(); }