File tree Expand file tree Collapse file tree 3 files changed +8
-2
lines changed
clerk-js/src/core/modules/checkout Expand file tree Collapse file tree 3 files changed +8
-2
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+ ' @clerk/clerk-js ' : patch
3
+ ' @clerk/types ' : patch
4
+ ---
5
+
6
+ Make ` .finalize() ` from useCheckout to return a Promise.
Original file line number Diff line number Diff line change @@ -64,7 +64,7 @@ function createCheckoutInstance(
64
64
65
65
const finalize = ( params ?: { redirectUrl : string } ) => {
66
66
const { redirectUrl } = params || { } ;
67
- void clerk . setActive ( { session : clerk . session ?. id , redirectUrl } ) ;
67
+ return clerk . setActive ( { session : clerk . session ?. id , redirectUrl } ) ;
68
68
} ;
69
69
70
70
const clear = ( ) => manager . clearCheckout ( ) ;
Original file line number Diff line number Diff line change @@ -91,7 +91,7 @@ export type __experimental_CheckoutInstance = {
91
91
confirm : ( params : ConfirmCheckoutParams ) => Promise < CheckoutResult > ;
92
92
start : ( ) => Promise < CheckoutResult > ;
93
93
clear : ( ) => void ;
94
- finalize : ( params ?: { redirectUrl : string } ) => void ;
94
+ finalize : ( params ?: { redirectUrl : string } ) => Promise < void > ;
95
95
subscribe : ( listener : ( state : __experimental_CheckoutCacheState ) => void ) => ( ) => void ;
96
96
getState : ( ) => __experimental_CheckoutCacheState ;
97
97
} ;
You can’t perform that action at this time.
0 commit comments