From f624bff6aee1e9d75691c71d1501d18dcd6d8986 Mon Sep 17 00:00:00 2001 From: andrewbents Date: Tue, 12 Nov 2024 17:00:39 +0100 Subject: [PATCH] Revert "Add orderId to success/error callbacks" (#89) * Revert "Add orderId to success/error callbacks (#88)" This reverts commit f26a2a13f9d9a2b3fd3fc4c1bd2c2a3548687ad3. --- src/types.ts | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/types.ts b/src/types.ts index d4078fc..6de6461 100644 --- a/src/types.ts +++ b/src/types.ts @@ -426,12 +426,9 @@ export interface CommonOptions { /** Controls the language of the text in the widget method */ locale?: Locale | 'auto' /** Callback will be called when the payment is completed successfully */ - onSuccess?: (payload: { orderId: string }) => void + onSuccess?: () => void /** Callback if transaction is failed to complete, the reason should be available in the message parameter */ - onError?: ( - error: RevolutCheckoutError, - payload: { orderId: string | undefined } - ) => void + onError?: (error: RevolutCheckoutError) => void /** Callback if an user did not complete the transaction and canceled the authorisation or closed the checkout window */ onCancel?: () => void /** Indicates in which case this saved payment method can be used for payments */