From 0a5dc77b9734cb6dff5bde4aba7ae7d68cbec024 Mon Sep 17 00:00:00 2001 From: Sipachev Igor Date: Mon, 30 Jan 2023 12:46:13 +0700 Subject: [PATCH] =?UTF-8?q?=D0=9F=D0=BE=D0=BF=D1=80=D0=B0=D0=B2=D0=B8?= =?UTF-8?q?=D0=BB=20=D0=BE=D0=BF=D1=80=D0=B5=D0=B4=D0=B5=D0=BB=D0=B5=D0=BD?= =?UTF-8?q?=D0=B8=D0=B5=20=D0=B1=D0=B0=D0=B7=D0=BE=D0=B2=D0=BE=D0=B3=D0=BE?= =?UTF-8?q?=20=D0=B0=D0=B4=D1=80=D0=B5=D1=81=D0=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- api/sm/sm-client.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/api/sm/sm-client.ts b/api/sm/sm-client.ts index c173693..badbcfe 100644 --- a/api/sm/sm-client.ts +++ b/api/sm/sm-client.ts @@ -17,8 +17,10 @@ import stopProcessSchema from "./schemas/stop-process"; import killProcessSchema from "./schemas/kill-process"; import commandSchema from "./schemas/command"; +let baseUrl = typeof location !== 'undefined' && location.origin.includes('.wallester.') ? location.origin : 'http://fmw.sipachev.sv' + export class SMClient extends SchemaClient { - baseUrl = 'http://fmw.sipachev.sv' + baseUrl = baseUrl async getCommands(): Promise> { let { responseData, headers } = await this.send(commandsSchema, {})