Repository navigation
Fix: add multiple domains to cart via sequential requests - #214
Open
hvidalnegreiros-godaddy wants to merge 1 commit into
Open
hvidalnegreiros-godaddy wants to merge 1 commit into
hvidalnegreiros-godaddy wants to merge 1 commit into
Conversation
Upgrade domain-search to v5.0.2, which fixes the Cart API only persisting the first domain when multiple domain items were sent in a single request. The widget now POSTs one domain at a time, sequentially, and navigates to the final nextStepUrl on success or shows an error and stops on the first failure. Adds e2e coverage for the multi-select add-to-cart flow and the abort-on-failure path.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
GoDaddy's Cart API only persists one domain-type cart item per POST — a single request containing multiple
items(even with distinctdomainvalues) results incartCountstaying at1. This meant selecting multiple domains in the Advanced Domain Search widget and clicking "Continue to Cart" only ever added the first one.domain-searchto v5.0.2, which fixes this upstream by sending one sequential POST per selected domain (reusing the session cookie established by the first call) instead of a single multi-item POST.assets/js/domain-search.min.js) and bumps plugin version to 3.0.2.Closes #209.
Test plan
cypress/e2e/09-domain-search-cart.cy.js: asserts sequential single-item POSTs in selection order and navigation to the finalnextStepUrlon success; asserts abort-on-first-failure shows an error and does not navigate.wp-envWordPress install: new spec passes (2/2) and full Cypress suite passes with no regressions (57/57).