-
Notifications
You must be signed in to change notification settings - Fork 58
Fix disabled functionality for Save PayPal and Venmo (PCP-4489) #3650
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
Fix disabled functionality for Save PayPal and Venmo (PCP-4489) #3650
Conversation
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.
Pull Request Overview
This PR fixes the disabled functionality for PayPal and Venmo metabox by correcting typos in property names and improving feature availability checks. It also enhances test coverage for the SavePaymentMethods component.
- Fixes typo where "ownBradOnly" was used instead of "ownBrandOnly" in multiple locations
- Adds proper feature availability check for save payment methods functionality
- Implements comprehensive test coverage for the SavePaymentMethods component
Reviewed Changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
tests/js/__mocks__/@wordpress/i18n.js |
Adds mock implementation for WordPress i18n functions to support testing |
modules/ppcp-wc-gateway/src/WCGatewayModule.php |
Enhances feature availability check by adding save payment methods eligibility validation |
modules/ppcp-settings/resources/js/Components/Screens/Settings/Tabs/TabSettings.js |
Fixes typo by removing incorrect "ownBradOnly" prop from CommonSettings |
modules/ppcp-settings/resources/js/Components/Screens/Settings/Components/Settings/CommonSettings.js |
Corrects parameter name from "ownBradOnly" to "ownBrandOnly" |
modules/ppcp-settings/resources/js/Components/Screens/Settings/Components/Settings/Blocks/SavePaymentMethods.test.js |
Adds comprehensive test suite for SavePaymentMethods component |
modules/ppcp-settings/resources/js/Components/Screens/Settings/Components/Settings/Blocks/SavePaymentMethods.js |
Fixes typo in parameter name and adds early return when feature is unavailable |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Test using WordPress PlaygroundThe changes in this pull request can be previewed and tested using a WordPress Playground instance. 🔗 Test this pull request with WordPress Playground What's included:
Login credentials:
Plugin Details:
🤖 Auto-generated for commit b3c8391 • Last updated: 2025-11-24T13:03:20.833Z |
Narek13
left a comment
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.
Thanks for working on this. Worked as expected for me.
…-country-does-not-support-vault
Description
Steps to Test
Demo
Screen.Recording.2025-09-10.at.18.55.50.mov