diff --git a/src/screens/HyperSwitch/Routing/AdvancedRouting/RoutingPreviewer.res b/src/screens/HyperSwitch/Routing/AdvancedRouting/RoutingPreviewer.res index f4f65963e..951b18891 100644 --- a/src/screens/HyperSwitch/Routing/AdvancedRouting/RoutingPreviewer.res +++ b/src/screens/HyperSwitch/Routing/AdvancedRouting/RoutingPreviewer.res @@ -4,7 +4,7 @@ open RoutingUtils module SimplePreview = { @react.component let make = (~gateways) => { - if gateways->Js.Array2.length > 0 { + Js.Array2.length > 0}>
React.array}
- } else { - React.null - } +
} } module GatewayView = { @@ -189,16 +187,15 @@ module RulePreviewer = { {React.string(string_of_int(index + 1))}
{gateway->React.string}
- {if index !== ruleInfo.default_gateways->Js.Array2.length - 1 { + Js.Array2.length - 1}> ()} /> - } else { - React.null - }} + }) ->React.array} diff --git a/src/screens/HyperSwitch/RoutingRevamp/AdvancedRoutingUIUtils.res b/src/screens/HyperSwitch/RoutingRevamp/AdvancedRoutingUIUtils.res index f2d08737e..31f8ce1d6 100644 --- a/src/screens/HyperSwitch/RoutingRevamp/AdvancedRoutingUIUtils.res +++ b/src/screens/HyperSwitch/RoutingRevamp/AdvancedRoutingUIUtils.res @@ -19,9 +19,10 @@ module LogicalOps = { {["AND", "OR"] - ->Js.Array2.map(text => { + ->Array.mapWithIndex((text, i) => { let active = logicalOpsInput.value->LogicUtils.getStringFromJson("") === text