Skip to content

Commit

Permalink
fix: comments addressed
Browse files Browse the repository at this point in the history
  • Loading branch information
ArushKapoorJuspay committed Mar 11, 2024
1 parent dee4452 commit 0d132a8
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 10 deletions.
7 changes: 1 addition & 6 deletions src/Components/PayNowButton.res
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@ let make = (
isExpiryValid->Option.getOr(false) &&
areRequiredFieldsValidValue

let buttonText =
sdkHandleConfirmPayment.buttonText->String.length > 0
? sdkHandleConfirmPayment.buttonText
: localeString.payNowButton

let confirmPayload = sdkHandleConfirmPayment->PaymentBody.confirmPayloadForSDKButton

let handleOnClick = _ => {
Expand Down Expand Up @@ -84,7 +79,7 @@ let make = (
{if showLoader {
<Loader />
} else {
buttonText->React.string
localeString.payNowButton->React.string
}}
</span>
</button>
Expand Down
1 change: 0 additions & 1 deletion src/LoaderController.res
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
open Utils
external toJson: 'a => Js.Json.t = "%identity"

@react.component
let make = (~children, ~paymentMode, ~setIntegrateErrorError, ~logger) => {
Expand Down
3 changes: 0 additions & 3 deletions src/Types/PaymentType.res
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,6 @@ type billingAddress = {

type sdkHandleConfirmPayment = {
handleConfirm: bool,
buttonText: string,
confirmParams: ConfirmType.confirmParams,
}

Expand Down Expand Up @@ -255,7 +254,6 @@ let defaultBillingAddress = {

let defaultSdkHandleConfirmPayment = {
handleConfirm: false,
buttonText: "Pay Now",
confirmParams: ConfirmType.defaultConfirm,
}

Expand Down Expand Up @@ -884,7 +882,6 @@ let getConfirmParams = dict => {

let getSdkHandleConfirmPaymentProps = dict => {
handleConfirm: dict->getBool("handleConfirm", false),
buttonText: dict->getString("buttonText", "Pay Now"),
confirmParams: dict->getDictfromDict("confirmParams")->getConfirmParams,
}

Expand Down

0 comments on commit 0d132a8

Please sign in to comment.