Skip to content

Conversation

@albarin
Copy link
Contributor

@albarin albarin commented Jul 10, 2025

Closes woocommerce/woocommerce#59319

This PR updates the manage_stock product variation property to be string or boolean. Before, it was documented only as boolean, but it can also return have the parent value when the variation inherits stock settings from the parent product.

Testing steps

  1. Run the build script found in the root of this repo: ./build.sh
  2. Find the build directory created by the script, and the index.html file within. Load that file in your web browser.
  3. Search for manage_stock occurrences and check that the type is "type": ["boolean", "string"] or boolean, string when the description refers to Stock management at variation level. (it should still be only boolean when the description is for the product level Stock management at product level.).
"manage_stock":
    "required": false,
    "default": false,
    "description": "Stock management at variation level.",
    "type": ["boolean", "string"]
}
  1. Repeat step 3 for v1 and v2 documentation as well.

@albarin albarin marked this pull request as ready for review July 10, 2025 10:18
@albarin albarin requested review from a team and joshuatf and removed request for a team July 10, 2025 10:22
Copy link

@joshuatf joshuatf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! Just added one clarifying comment.

@albarin albarin requested a review from joshuatf July 23, 2025 12:30
Copy link

@joshuatf joshuatf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thanks for the changes 😄

@albarin albarin merged commit d7a9fc4 into trunk Jul 24, 2025
@NeosinneR NeosinneR deleted the 59319/fix-manage-stock-type branch August 1, 2025 09:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[DOC-BUG] Incorect propery type

3 participants