This repository has been archived by the owner on Feb 23, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 219
Check for null session before going setting up tax address #8537
Merged
senadir
merged 1 commit into
trunk
from
fix/check-for-session-before-getting-tax-address
Feb 24, 2023
Merged
Check for null session before going setting up tax address #8537
senadir
merged 1 commit into
trunk
from
fix/check-for-session-before-getting-tax-address
Feb 24, 2023
Conversation
This file contains 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
senadir
added
status: blocker
Used on issues or pulls that block work from being released.
block: checkout
Issues related to the checkout block.
priority: critical
The issue is critical—e.g. a fatal error, security problem affecting many customers.
labels
Feb 24, 2023
The release ZIP for this PR is accessible via:
Script Dependencies ReportThe
This comment was automatically generated by the TypeScript Errors Report
🎉 🎉 This PR does not introduce new TS errors. |
Size Change: 0 B Total Size: 1.1 MB ℹ️ View Unchanged
|
opr
approved these changes
Feb 24, 2023
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.
I tested that this stops the fatal error and it does 👌🏼
7 tasks
gigitux
pushed a commit
that referenced
this pull request
Feb 27, 2023
tarhi-saad
pushed a commit
that referenced
this pull request
Feb 27, 2023
gigitux
added a commit
that referenced
this pull request
Feb 27, 2023
* Empty commit for release pull request * update readme * Switch to select instead of resolveSelector (#8356) * Mini Cart block - Fix the drawer content height to allow checkout button to show. (#8351) * Add max-height to Mini Cart drawer. By giving the Mini Cart contents a max height with the -webkit-fill-available property, we can ensure that the browser chrome is accounted for on mobile devices. * Add `dvh` and keep `vh` as a fallback for height. By adding `dvh`, we also account for non-webkit mobile browsers that have the same hidden button issue. See #8351 (review) Keeping `vh` as a fallback, along with `-webkit-fill-available` gives us the widest range of support. * update readme with changelog * add testing steps * add pr links to readme * Bumping version strings to new version. * Check for null session before going forward (#8537) * add testing instructions * Empty commit for release pull request * add zip link * Update zip link * update zip link for testing * Bumping version strings to new version. --------- Co-authored-by: github-actions <github-actions@github.com> Co-authored-by: Nadir Seghir <nadir.seghir@gmail.com> Co-authored-by: Daniel W. Robert <danielwrobert@users.noreply.github.com> Co-authored-by: Luigi <gigitux@gmail.com> Co-authored-by: Paulo Arromba <17236129+wavvves@users.noreply.github.com>
tarhi-saad
added a commit
that referenced
this pull request
Feb 27, 2023
* Empty commit for release pull request * Add changelog in readme.txt * Add testing notes * Remove change from testing notes This requires AvaTax credentials for testing. So, we'll test for regressions instead * Check for null session before going forward (#8537) * Fix Payment Options settings crash in the editor (#8535) * Ensure express payment buttons are visible next to each other (#8548) * Update ZIP file * Bumping version strings to new version. --------- Co-authored-by: github-actions <github-actions@github.com> Co-authored-by: Saad Tarhi <saad.trh@gmail.com> Co-authored-by: Seghir Nadir <nadir.seghir@gmail.com> Co-authored-by: Niels Lange <info@nielslange.de>
nielslange
added a commit
that referenced
this pull request
Mar 3, 2023
* Empty commit for release pull request * Add changelog to readme.txt * Unset default customer state if it doesn't match country (#8460) * Unset default state * add controller for customers * rename validation file * explain fix inline * address feedback * revert back state logic * Update src/StoreApi/Utilities/ValidationUtils.php Co-authored-by: Mike Jolley <mike.jolley@me.com> --------- Co-authored-by: Mike Jolley <mike.jolley@me.com> * Update readme.txt * Add testing notes * Update testing notes * Fix Customer account sidebar link incorrect margin in WP 6.2 (#8437) * Fix Customer account sidebar link incorrect margin in WP 6.2 * Update class name to match the guidelines * Prevent cart from breaking when item_data contains an array (#8440) * Ensure array item data is removed * Remove unused key * Clean up code and add comments * Check for null instead of empty * Use plain foreach to filter and map arrays * Add minimum height to Mini Cart Contents block in the Style Book (#8458) * Update testing notes zip file * Update testing notes * Update testing notes file * Bumping version strings to new version. * Empty commit for release pull request * Empty commit for release pull request * disable compatibilty layer (#8507) * update changelog and testing instructions * add zip link * Bumping version strings to new version. * Empty commit for release pull request * Empty commit for release pull request * Add changelog in readme.txt * Add testing notes * Remove change from testing notes This requires AvaTax credentials for testing. So, we'll test for regressions instead * Check for null session before going forward (#8537) * Fix Payment Options settings crash in the editor (#8535) * Ensure express payment buttons are visible next to each other (#8548) * Update ZIP file * Bumping version strings to new version. * Empty commit for release pull request * Empty commit for release pull request --------- Co-authored-by: github-actions <github-actions@github.com> Co-authored-by: Saad Tarhi <saad.trh@gmail.com> Co-authored-by: Seghir Nadir <nadir.seghir@gmail.com> Co-authored-by: Mike Jolley <mike.jolley@me.com> Co-authored-by: Albert Juhé Lluveras <contact@albertjuhe.com> Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com> Co-authored-by: Luigi Teschio <gigitux@gmail.com> Co-authored-by: Niels Lange <info@nielslange.de>
gigitux
added a commit
that referenced
this pull request
Mar 17, 2023
* Empty commit for release pull request * Add changelog to readme.txt * Unset default customer state if it doesn't match country (#8460) * Unset default state * add controller for customers * rename validation file * explain fix inline * address feedback * revert back state logic * Update src/StoreApi/Utilities/ValidationUtils.php Co-authored-by: Mike Jolley <mike.jolley@me.com> --------- Co-authored-by: Mike Jolley <mike.jolley@me.com> * Update readme.txt * Add testing notes * Update testing notes * Fix Customer account sidebar link incorrect margin in WP 6.2 (#8437) * Fix Customer account sidebar link incorrect margin in WP 6.2 * Update class name to match the guidelines * Prevent cart from breaking when item_data contains an array (#8440) * Ensure array item data is removed * Remove unused key * Clean up code and add comments * Check for null instead of empty * Use plain foreach to filter and map arrays * Add minimum height to Mini Cart Contents block in the Style Book (#8458) * Update testing notes zip file * Update testing notes * Update testing notes file * Bumping version strings to new version. * Empty commit for release pull request * Empty commit for release pull request * disable compatibilty layer (#8507) * update changelog and testing instructions * add zip link * Bumping version strings to new version. * Empty commit for release pull request * Empty commit for release pull request * Add changelog in readme.txt * Add testing notes * Remove change from testing notes This requires AvaTax credentials for testing. So, we'll test for regressions instead * Check for null session before going forward (#8537) * Fix Payment Options settings crash in the editor (#8535) * Ensure express payment buttons are visible next to each other (#8548) * Update ZIP file * Bumping version strings to new version. * Empty commit for release pull request * Empty commit for release pull request * Update readme.txt * Show three Express Payments buttons in-line (#8601) * Add testing notes * Bumping version strings to new version. * Empty commit for release pull request * Empty commit for release pull request * Add changelog in readme.txt * Undo dirty prop removal on error (#8633) Co-authored-by: Saad Tarhi <saad.trh@gmail.com> * Add testing notes * fix 404 error (#8445) * Empty commit for release pull request * add testing instruction * update zip link * fix version --------- Co-authored-by: github-actions <github-actions@github.com> Co-authored-by: Saad Tarhi <saad.trh@gmail.com> Co-authored-by: Seghir Nadir <nadir.seghir@gmail.com> Co-authored-by: Mike Jolley <mike.jolley@me.com> Co-authored-by: Albert Juhé Lluveras <contact@albertjuhe.com> Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com> Co-authored-by: Luigi Teschio <gigitux@gmail.com> Co-authored-by: Niels Lange <info@nielslange.de>
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
block: checkout
Issues related to the checkout block.
priority: critical
The issue is critical—e.g. a fatal error, security problem affecting many customers.
status: blocker
Used on issues or pulls that block work from being released.
type: bug
The issue/PR concerns a confirmed bug.
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.
This PR is pulled from #8529 The original PR does too much, and we prefer to commit to that solution yet. This change alone is enough to fix Avatax's issue.
Avatax seems to duplicate WC_Customer->get_taxable_address to avoid the session issue in order context, they still trigger the
woocommerce_customer_taxable_address
filter, which we hook into and use session.Another fix would be to change Avatax code, and instead of rebuilding
get_taxable_address
, just use WC_Abstract_Order->get_tax_location, for now, that function is protected, the plan is to make it public in WooCommerce core and switch Avatax to it.If we can't make it public, instead of having Avatax copy
WC_Customer->get_taxable_address
, they just copyWC_Abstract_Order->get_tax_location
.This doesn't fix the issue of Avatax using the wrong tax address when checking out a Checkout Block + new Local Pickup + Renewal order, they will end up using the store address, but that's an acceptable tradeoff for now.
Fixes #8473
Testing
Changelog