You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
POST /admin/collections/products/2 200 in 37ms
[23:37:55] INFO: A 'products' document has changed in Payload with ID: 'undefined', syncing with Stripe...
[23:37:55] INFO: A 'products' document has changed in Payload with ID: 'undefined', syncing with Stripe...
[23:37:55] INFO: - Syncing to Stripe resource with ID: 'prod_RR6yy2zDLbpBPU'...
[23:37:56] INFO: ✅ Successfully synced Stripe resource with ID: 'prod_RR6yy2zDLbpBPU'.
Describe the Bug
2 bugs in 1, Christmas special!
https://github.com/payloadcms/payload/blob/main/packages/plugin-stripe/src/hooks/createNewInStripe.ts#L70
This should only cater for
create
action, instead it picks up update action, prints to console and does nothing. Just remove the whole update piece?https://github.com/payloadcms/payload/blob/main/packages/plugin-stripe/src/hooks/syncExistingWithStripe.ts#L54
Looks like the
_id
property onoriginalDoc
is undefined here. Leftover from v2?See log output
Link to the code that reproduces this issue
https://github.com/payloadcms/payload/blob/main/packages/plugin-stripe/src/hooks/createNewInStripe.ts#L70
https://github.com/payloadcms/payload/blob/main/packages/plugin-stripe/src/hooks/syncExistingWithStripe.ts#L54
Reproduction Steps
products
Which area(s) are affected? (Select all that apply)
plugin: stripe
Environment Info
The text was updated successfully, but these errors were encountered: