Skip to content
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

Use correct class name for Link when disabling it for Checkout editor page #3547

Conversation

senadir
Copy link
Member

@senadir senadir commented Oct 25, 2024

This is a follow up to #3516 in which a refactor I made at last moment made that PR useless. This PR fixes that.

Testing instructions

  1. Ensure Link is working fine.
  2. In Checkout editor page, Link shouldn't show as not compatible.

@senadir senadir added type: bug The issue is a confirmed bug. component: stripe link Issues related to Stripe Link labels Oct 25, 2024
@senadir senadir self-assigned this Oct 25, 2024
Copy link
Contributor

@james-allan james-allan left a comment

Choose a reason for hiding this comment

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

This looks good to me.

I noticed while testing that I was stilling seeing an incomplete notice.

Screenshot 2024-10-30 at 12 11 18 pm
"" does not yet support this block

I found in the previous PR that this is being fixed in WC core via woocommerce/woocommerce#52070. It will now use the $title rather than $method_title.

Screenshot 2024-10-30 at 12 18 14 pm

That does make me wonder what the difference is between $title and $method_title and whether the fact that our payment methods which don't always set the $method_title may be missing. 🤔

From the WC_Payment_Gateway class definition, it looks like method_title is the backend title and title is the frontend. 🤷‍♂️ In any case we should probably tidy that up.

I also confirmed while on this branch that Link still works on the backend and frontend as you'd expect.

@senadir
Copy link
Member Author

senadir commented Nov 7, 2024

Yes I wasn't sure what's the different tbh and Link doesn't seem to have the method title, just the title. For our side, we try our best to find a title to show.

@senadir senadir merged commit a549835 into develop Nov 7, 2024
34 of 35 checks passed
@senadir senadir deleted the fix/use-correct-checking-method-when-disabling-link-in-checkout branch November 7, 2024 17:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: stripe link Issues related to Stripe Link type: bug The issue is a confirmed bug.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants