Jetpack Donations Block: Plan IDs disappear
Impacted plugin
Jetpack
Steps to Reproduce
- Go to page with Donations Block as a logged in user that is not the Jetpack plan owner
- Edit any content on the page.
- Save the page.
- View page and test Donation block.
This error appears:
A clear and concise description of what you expected to happen.
Any site user with admin/editing permissions should be able to go to a page with the donation block, edit content on the page, and publish the changes.
When viewing the updated page, the donation block should still function properly and accept transactions.
What actually happened
- A non-Jetpack plan owner but admin to the site made a text update to a page.
- Saving that somehow removed the plan IDs from the Jetpack donation block
- Without the plan IDs the donation block won’t work
- Logging in as the Jetpack plan owner, clicking on the Jetpack donation block, and then viewing the code view behind the blocks (in the block editor) showed that the plan IDs came back
- Saving the page with the plan IDs back in the block made the block work again.
Missing Plan IDs

Other information
Working Theory: Editing the page content as a different user from the Jetpack plan owner, for some reason, removes the Plan IDs
for each of the donation amounts.
Plan IDs restored:
Operating System
macOS
OS Version
Catalina 10.15.7
Browser
Chrome/Chromium
Browser Version(s)
Version 96.0.4664.55
2 Answer:
Yeah, I can reproduce this and seems to be the missing planID indeed and something that has been broken for a while in my testing:
Undefined index: planId in /srv/users/user5d76e790/apps/user5d76e790/public/wp-content/plugins/jetpack/extensions/blocks/donations/donations.php on line 143
@mmtr, I believe you worked on some donations block stuff somewhat recently. Would this be something we could take a look at?
@sdixon194 I don't have enough availability at the moment, but I'm happy to take a look next week as part of my 20% time (see p9MPsk-1iY-p2#comment-12243). @obenland also suggested to include it as part of the first iteration of the Payment Blocks in 2022 (see p9MPsk-1iY-p2#comment-1225).
Read next
- jetpack fix/20806 Browser console deprecation warning for BlcokControl entity
- jetpack cookies & Consents Banner Widget: Refuse / Don't Consent Button
- jetpack stats: add filter or option to exlude specific IP from stats
- jetpack dev Environment instructions improvement needed
- jetpack use layout components in backup admin
- jetpack fix some styling inconsistencies in the disconnect flow
- jetpack rNA buttons: add styles and storybook documentation
- jetpack widget visibility: supporting load conditions for legacy widgets in gutenberg widgets screen