This repository was archived by the owner on Feb 23, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 218
Display correct block template when filtering by attribute #7640
Merged
Aljullu
merged 1 commit into
trunk
from
fix/7604-wrong-template-when-filter-by-attribute
Nov 11, 2022
Merged
Display correct block template when filtering by attribute #7640
Aljullu
merged 1 commit into
trunk
from
fix/7604-wrong-template-when-filter-by-attribute
Nov 11, 2022
Conversation
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
The release ZIP for this PR is accessible via:
|
TypeScript Errors ReportFiles with errors: 446 🎉 🎉 This PR does not introduce new TS errors. |
Script Dependencies ReportThe
This comment was automatically generated by the |
Size Change: 0 B Total Size: 999 kB ℹ️ View Unchanged
|
albarin
approved these changes
Nov 11, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! 👏
4 tasks
senadir
pushed a commit
to senadir/woocommerce-blocks
that referenced
this pull request
Nov 12, 2022
albarin
pushed a commit
that referenced
this pull request
Nov 14, 2022
albarin
added a commit
that referenced
this pull request
Nov 14, 2022
* Empty commit for release pull request * Display correct block template when filtering by attribute (#7640) * Fix error when trying to access the queried object when it's null (#7664) * Fix error when trying to access the queried object when it's null. * Check if the `slug` exists * Use the taxonomy name instead of the slug, otherwise it returns false * Update readme changelog * Add testing notes * Improve testing notes format * Bumping version strings to new version. Co-authored-by: github-actions <[email protected]> Co-authored-by: Albert Juhé Lluveras <[email protected]> Co-authored-by: Alba Rincón <[email protected]> Co-authored-by: Alba Rincón <[email protected]>
gigitux
added a commit
that referenced
this pull request
Dec 1, 2022
* Empty commit for release pull request * Display correct block template when filtering by attribute (#7640) * Fix error when trying to access the queried object when it's null (#7664) * Fix error when trying to access the queried object when it's null. * Check if the `slug` exists * Use the taxonomy name instead of the slug, otherwise it returns false * Update readme changelog * Add testing notes * Improve testing notes format * Bumping version strings to new version. * Prevent Mini Cart loading the same script twice (#7794) * Empty commit for release pull request * update changelog * add testing instructions * update zip file link * Mini Cart: load wc-blocks-registry package at the load of the page instead of lazy load it (#7813) * update changelog * update testing instructions * update zip file link * Bumping version strings to new version. Co-authored-by: github-actions <[email protected]> Co-authored-by: Albert Juhé Lluveras <[email protected]> Co-authored-by: Alba Rincón <[email protected]> Co-authored-by: Alba Rincón <[email protected]> Co-authored-by: Luigi <[email protected]>
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Fixes #7604.
I'm not completely sure what was going with this issue, but it looks like when an attribute filter was enabled,
get_query_var( 'taxonomy' )
was returning that attribute, causing the Products by Attribute template logic to fire. I refactored that code to check forget_queried_object()
instead, that value doesn't change when an attribute filter is enabled.Testing
Automated Tests
User Facing Testing
Test that #7604 has been fixed
/product-category/clothing/
).Test that there are no regressions with #6776
Products
>Attributes
and edit an existing one or create a new one.Enable Archives
option and save, go back.Configure terms
next to your attribute.View
link of one of the attributes.WooCommerce Visibility
Performance Impact
Changelog