Skip to content

Commit

Permalink
Stepper: Add queue possibility to record signup completion (#95482)
Browse files Browse the repository at this point in the history
  • Loading branch information
escapemanuele authored Oct 17, 2024
1 parent b1d31bb commit 5fed8dd
Showing 1 changed file with 20 additions and 23 deletions.
43 changes: 20 additions & 23 deletions client/landing/stepper/hooks/use-record-signup-complete.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,29 +53,26 @@ export const useRecordSignupComplete = ( flow: string | null ) => {
const hasPaidDomainItem =
( selectedDomain && ! selectedDomain.is_free ) || !! domainProductSlug;

recordSignupComplete(
{
flow,
siteId: siteId ?? signupCompletionState?.siteId,
isNewUser,
hasCartItems,
isNew7DUserSite,
theme,
intent: flow,
startingPoint: flow,
isBlankCanvas: theme?.includes( 'blank-canvas' ),
planProductSlug,
domainProductSlug,
isMapping:
hasPaidDomainItem && domainCartItem ? isDomainMapping( domainCartItem ) : undefined,
isTransfer:
hasPaidDomainItem && domainCartItem ? isDomainTransfer( domainCartItem ) : undefined,
signupDomainOrigin: signupDomainOrigin ?? SIGNUP_DOMAIN_ORIGIN.NOT_SET,
framework: 'stepper',
isNewishUser,
},
true
);
recordSignupComplete( {
flow,
siteId: siteId ?? signupCompletionState?.siteId,
isNewUser,
hasCartItems,
isNew7DUserSite,
theme,
intent: flow,
startingPoint: flow,
isBlankCanvas: theme?.includes( 'blank-canvas' ),
planProductSlug,
domainProductSlug,
isMapping:
hasPaidDomainItem && domainCartItem ? isDomainMapping( domainCartItem ) : undefined,
isTransfer:
hasPaidDomainItem && domainCartItem ? isDomainTransfer( domainCartItem ) : undefined,
signupDomainOrigin: signupDomainOrigin ?? SIGNUP_DOMAIN_ORIGIN.NOT_SET,
framework: 'stepper',
isNewishUser,
} );
},
[
domainCartItem,
Expand Down

0 comments on commit 5fed8dd

Please sign in to comment.