Automattic / wp-calypso

The JavaScript and API powered WordPress.com
https://developer.wordpress.com
GNU General Public License v2.0
12.42k stars 1.99k forks source link

Some steps of the signup flow perform unexpected function calls #47834

Open dzver opened 3 years ago

dzver commented 3 years ago

Steps to reproduce

  1. Starting at URL: /start/launch-site with a new site
  2. Select Free plan and Free domain

What I expected

What happened instead

Add to cart with empty parameters.

I'm not sure if that has any negative impact on the code but debugging it is confusing. I think adding some more ifs so that empty domains/plans don't go to the cart functions.

razvanpapadopol commented 3 years ago

I think @Automattic/shilling did some work recently on adding to cart functionality. Is this still an issue?

sirbrillig commented 3 years ago

Add to cart with empty parameters.

Interesting! I'm not sure, but it sounds like this could have been related to the fix in https://github.com/Automattic/wp-calypso/pull/52560

I just did a quick test of this flow, and I do see that signup still fetches the cart twice (once on the first launch flow page, and once on the second page), although nothing is added to the cart, so I'm not sure if that means this issue is resolved or not.