Skip to content

Commit

Permalink
fix: connector type
Browse files Browse the repository at this point in the history
  • Loading branch information
JeevaRamu0104 committed Feb 29, 2024
1 parent 4ac154c commit 8037fa5
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/screens/StripePlusPaypal/StripePlusPaypal.res
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ let make = () => {
}

let handleNavigation = async (~forward: bool) => {
if selectedConnector === Processors(STRIPE) {
if enums.paypalConnected.processorID->String.length === 0 {
switch selectedConnector {
| Processors(STRIPE) => if enums.paypalConnected.processorID->String.length === 0 {
setSelectedConnector(_ => Processors(PAYPAL))
setConnectorConfigureState(_ => Configure_keys)
setInitialValues(_ => Dict.make()->JSON.Encode.object)
Expand All @@ -42,8 +42,7 @@ let make = () => {
}
})
}
} else {
setStepInView(_ => TEST_PAYMENT)
| _ => setStepInView(_ => TEST_PAYMENT)
}
}

Expand Down

0 comments on commit 8037fa5

Please sign in to comment.