aboutsummaryrefslogtreecommitdiff
path: root/packages/merchant-backoffice-ui/src/hooks/index.ts
diff options
context:
space:
mode:
authorSebastian <sebasjm@gmail.com>2023-10-06 10:38:09 -0300
committerSebastian <sebasjm@gmail.com>2023-10-06 10:38:23 -0300
commit98013322db6b912ac50d72353dbd8b5f7fbc0435 (patch)
tree184b99e08c69f131fe26628bbb106633d7d66013 /packages/merchant-backoffice-ui/src/hooks/index.ts
parent97d7be7503168f4f3bbd05905d32aa76ca1636b2 (diff)
downloadwallet-core-98013322db6b912ac50d72353dbd8b5f7fbc0435.tar.xz
backoffice ui
Diffstat (limited to 'packages/merchant-backoffice-ui/src/hooks/index.ts')
-rw-r--r--packages/merchant-backoffice-ui/src/hooks/index.ts8
1 files changed, 7 insertions, 1 deletions
diff --git a/packages/merchant-backoffice-ui/src/hooks/index.ts b/packages/merchant-backoffice-ui/src/hooks/index.ts
index 498e4eb78..3c8ef15ed 100644
--- a/packages/merchant-backoffice-ui/src/hooks/index.ts
+++ b/packages/merchant-backoffice-ui/src/hooks/index.ts
@@ -32,7 +32,13 @@ const calculateRootPath = () => {
? window.location.origin + window.location.pathname
: "/";
- return rootPath.replace("webui/","");
+ /**
+ * By default, merchant backend serves the html content
+ * from the /webui root. This should cover most of the
+ * cases and the rootPath will be the merchant backend
+ * URL where the instances are
+ */
+ return rootPath.replace("/webui/", "");
};
const loginTokenCodec = buildCodecForObject<LoginToken>()