Skip to content

Commit

Permalink
Add inline from check to jetpack authorize to have unit tests pass
Browse files Browse the repository at this point in the history
  • Loading branch information
ciampo committed Feb 11, 2025
1 parent a67614f commit e19f76b
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion client/jetpack-connect/authorize.js
Original file line number Diff line number Diff line change
Expand Up @@ -453,7 +453,14 @@ export class JetpackAuthorize extends Component {

isWooJPC( props = this.props ) {
const { from } = props.authQuery;
return 'woocommerce-core-profiler' === from || this.props.isWooJPC;
return (
// TODO: the two extra `from` checks shouldn't be necessary,
// as they should be embedded in the isWooJPCFlow. But the unit
// tests don't use the connected component
'woocommerce-core-profiler' === from ||
'woocommerce-onboarding' === from ||
this.props.isWooJPC
);
}

getWooDnaConfig( props = this.props ) {
Expand Down

0 comments on commit e19f76b

Please sign in to comment.