From ecb744096ba74f230e1fdfa9bac34bec685d2a3a Mon Sep 17 00:00:00 2001 From: Vrishab Srivatsa Date: Tue, 30 Apr 2024 13:25:13 +0530 Subject: [PATCH] fix: reverted only confirm endpoint on webpack --- src/orca-loader/Elements.res | 5 ----- src/orca-loader/Types.res | 2 +- webpack.common.js | 6 +++--- 3 files changed, 4 insertions(+), 9 deletions(-) diff --git a/src/orca-loader/Elements.res b/src/orca-loader/Elements.res index 57adb5e1c..5ea77b0d5 100644 --- a/src/orca-loader/Elements.res +++ b/src/orca-loader/Elements.res @@ -10,8 +10,6 @@ type trustPayFunctions = { executeGooglePayment: (string, GooglePayType.paymentDataRequest) => Promise.t, } @new external trustPayApi: JSON.t => trustPayFunctions = "TrustPayApi" -@val @scope("window") -external alert: 't => unit = "alert" let make = ( options, @@ -454,9 +452,6 @@ let make = ( switch dict->Dict.get("applePayButtonClicked") { | Some(val) => if val->JSON.Decode.bool->Belt.Option.getWithDefault(false) { - alert(event) - alert("event.isTrusted handleApplePayThirdPartyFlow") - alert(event.isTrusted) let applePaySessionTokenData = dict ->Dict.get("applePayPresent") diff --git a/src/orca-loader/Types.res b/src/orca-loader/Types.res index efcb52b4d..af364c201 100644 --- a/src/orca-loader/Types.res +++ b/src/orca-loader/Types.res @@ -10,7 +10,7 @@ type eventData = { confirmTriggered: bool, oneClickConfirmTriggered: bool, } -type event = {key: string, data: eventData, isTrusted: bool} +type event = {key: string, data: eventData} type eventParam = Event(event) | EventData(eventData) | Empty type eventHandler = option => unit @send external onload: (Dom.element, unit => Promise.t<'a>) => Promise.t<'a> = "onload" diff --git a/webpack.common.js b/webpack.common.js index 6802ee965..ce9579d0d 100644 --- a/webpack.common.js +++ b/webpack.common.js @@ -39,12 +39,12 @@ let backendEndPoint; if (envBackendUrl === undefined) { backendEndPoint = sdkEnv === "prod" - ? "https://api.hyperswitch.io" + ? "https://checkout.hyperswitch.io/api" : sdkEnv === "sandbox" - ? "https://sandbox.hyperswitch.io" + ? "https://beta.hyperswitch.io/api" : sdkEnv === "integ" ? "https://integ-api.hyperswitch.io" - : "https://sandbox.hyperswitch.io"; + : "https://beta.hyperswitch.io/api"; } else { backendEndPoint = envBackendUrl; }