From a4ad1ca30060b6adfff66eed5864605c5806c7e9 Mon Sep 17 00:00:00 2001 From: CaisManai Date: Tue, 31 Oct 2023 16:56:16 +0000 Subject: [PATCH] Adding correct params --- tools/walletextension/api/staticOG/javascript.js | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/tools/walletextension/api/staticOG/javascript.js b/tools/walletextension/api/staticOG/javascript.js index 8476fc03cc..830b2c3fa8 100644 --- a/tools/walletextension/api/staticOG/javascript.js +++ b/tools/walletextension/api/staticOG/javascript.js @@ -1,4 +1,3 @@ -const gatewayaddress = "https://testnet.obscu.ro" const eventClick = "click"; const eventDomLoaded = "DOMContentLoaded"; const idJoin = "join"; @@ -14,11 +13,11 @@ const idRequestTokens = "requestTokens"; const idBegin = "begin-box"; const idSpinner = "spinner"; const obscuroGatewayVersion = "v1"; -const pathJoin = gatewayaddress + "/" + obscuroGatewayVersion + "/join/"; -const pathAuthenticate = gatewayaddress + "/" + obscuroGatewayVersion + "/authenticate/"; -const pathQuery = gatewayaddress + "/" + obscuroGatewayVersion + "/query/"; -const pathRevoke = gatewayaddress + "/" + obscuroGatewayVersion + "/revoke/"; -const pathVersion = gatewayaddress + "/" + "version/"; +const pathJoin = obscuroGatewayVersion + "/join/"; +const pathAuthenticate = obscuroGatewayVersion + "/authenticate/"; +const pathQuery = obscuroGatewayVersion + "/query/"; +const pathRevoke = obscuroGatewayVersion + "/revoke/"; +const pathVersion = "/version/"; const obscuroChainIDDecimal = 443; const methodPost = "post"; const methodGet = "get"; @@ -34,7 +33,7 @@ function isValidUserIDFormat(value) { return typeof value === 'string' && value.length === 64; } -let obscuroGatewayAddress = gatewayaddress; +let obscuroGatewayAddress = window.location.protocol + "//" + window.location.host; let provider = null;