Skip to content

Conversation

@dd32
Copy link
Member

@dd32 dd32 commented Jul 14, 2025

Various blocks are made available through the site editor, such as on WordCamp.

These mean the block can be previewed, which may generate warnings such as this:

E_WARNING Undefined array key "postId"
URL  https://example.wordcamp.org/2025/wp-json/wp/v2/block-renderer/wporg/favorite-button?context=edit&attributes%5BshowCount%5D=false&attributes%5Bvariant%5D=default&_locale=user
File  pub-sync/blocks/favorite-button/render.php:10

Whether these blocks should be presented for insertion is one thing, but avoiding the warning and returning nothing would be nice.

@dd32 dd32 added [Type] Bug Something isn't working [Block] Favorite Button labels Jul 14, 2025
@dd32 dd32 merged commit 62b0651 into trunk Sep 9, 2025
2 checks passed
@dd32 dd32 deleted the fix/warning-favorites-button branch September 9, 2025 03:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants