From a9844988ee15fe40a2e7ba2b38f6c49fbe31b5a8 Mon Sep 17 00:00:00 2001
From: Praful Koppalkar <126236898+prafulkoppalkar@users.noreply.github.com>
Date: Fri, 7 Jun 2024 18:42:15 +0530
Subject: [PATCH] fix: redirect issue (#432)

---
 src/orca-loader/Hyper.res | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/src/orca-loader/Hyper.res b/src/orca-loader/Hyper.res
index 7adabb05c..22349cf94 100644
--- a/src/orca-loader/Hyper.res
+++ b/src/orca-loader/Hyper.res
@@ -277,11 +277,7 @@ let make = (publishableKey, options: option<JSON.t>, analyticsInfo: option<JSON.
           ->Option.flatMap(x => x->Dict.get("confirmParams"))
           ->Option.getOr(Dict.make()->JSON.Encode.object)
 
-        let redirect =
-          payload
-          ->getDictFromJson
-          ->getDictfromDict("confirmParams")
-          ->getString("redirect", "if_required")
+        let redirect = payload->getDictFromJson->getString("redirect", "if_required")
 
         let url =
           confirmParams