From 66bf577676be48a82790756f8a26841ff19916f4 Mon Sep 17 00:00:00 2001 From: RaktimaNXG Date: Tue, 7 May 2024 09:54:10 +0530 Subject: [PATCH] refactor: add comment --- apps/OpenSign/src/pages/GuestLogin.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/apps/OpenSign/src/pages/GuestLogin.js b/apps/OpenSign/src/pages/GuestLogin.js index 78f4ce2fa..409b29fb0 100644 --- a/apps/OpenSign/src/pages/GuestLogin.js +++ b/apps/OpenSign/src/pages/GuestLogin.js @@ -40,7 +40,7 @@ function GuestLogin() { localStorage.clear(); let parseId, appName, newServer; - //first condition is used to handle old route data url that already save + //first condition is used to manage previously stored URL data for the old route. if (id) { //split url in array from '&' const checkSplit = serverUrl.split("&"); @@ -50,9 +50,11 @@ function GuestLogin() { newServer = server.replaceAll("%2F", "/"); setEmail(userMail); } else { + //in this condition decode base64 route to in string and save required dataf. parseId = appInfo.appId; newServer = `${appInfo.baseUrl}/`; appName = appInfo.appname; + //`atob` function is used to decode base64 const decodebase64 = atob(base64url); //split url in array from '/' const checkSplit = decodebase64.split("/");