Make WordPress Core

Opened 14 months ago

Closed 14 months ago

Last modified 4 days ago

#63191 closed defect (bug) (invalid)

Plugin status

Reported by: dilip04's profile dilip04 Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: General Keywords: has-patch has-unit-tests
Focuses: Cc:

Description

Hello

I had uploaded a plugin earlier, and there were some issues reported from the WordPress end. I have fixed those issues and re-uploaded the plugin. However, I am unable to check its current status. Could you please let me know the latest status of the plugin?

Thanks.

Change History (4)

#1 @audrasjb
14 months ago

  • Milestone Awaiting Review deleted
  • Resolution set to invalid
  • Status changed from new to closed

Hello, you are on WordPress Core Trac, a place where we work on WordPress Core development.

Please send an email to plugins@wordpress.org and just wait for their answer (this may take several days or week).

Closing this ticket as invalid.

This ticket was mentioned in PR #10930 on WordPress/wordpress-develop by @adamsilverstein.


3 months ago
#2

  • Keywords has-patch has-unit-tests added

## Summary

Introduces the reaction comment type to support emoji reactions on collaborative Notes, replacing the previous _wp_note_reactions meta approach from Gutenberg PR #75148 (now closed in favor of #75549).

Each reaction is stored as a separate comment with comment_type = 'reaction' rather than as serialized meta data on the note.

## Changes

  • Avatar support: Add reaction to the allowed avatar comment types
  • Admin exclusions: Exclude reactions from the admin comment list table and comment type filter
  • Comment counts: Exclude reactions from approved and pending comment count queries
  • REST API: Extend WP_REST_Comments_Controller to handle reaction type:
    • Permissions checks treat reactions like notes (edit_comment/edit_post instead of moderate_comments)
    • Validation: parent must be a note, content must be a valid emoji slug (heart, celebration, smile, eyes, rocket), one emoji per user per note
    • Auto-approve reactions (skip spam/flood checks)
    • Read permission and link embedding match note behavior
  • Tests: PHPUnit tests for reaction creation, invalid parent, invalid emoji, duplicate detection, different reactions on same note, login requirement, and comment count exclusion
  • Fixtures: Regenerated wp-api-generated.js

## Trac ticket

See https://core.trac.wordpress.org/ticket/63191

## Test plan

  • [ ] Create a note on a post via the REST API
  • [ ] Add a heart reaction to the note — should succeed (201)
  • [ ] Attempt a reaction on a regular comment — should fail (400)
  • [ ] Attempt an invalid emoji slug — should fail (400)
  • [ ] Attempt a duplicate reaction (same emoji, same user, same note) — should fail (409)
  • [ ] Add a different emoji (rocket) to the same note — should succeed
  • [ ] Verify reactions don't appear in wp-admin Comments list
  • [ ] Verify reactions don't affect post comment counts
  • [ ] Run phpunit --filter=test_create_reaction — all pass
  • [ ] Run phpunit tests/phpunit/tests/comment/wpUpdateCommentCountNow.php — all pass

🤖 Generated with Claude Code

@adamsilverstein commented on PR #10930:


3 months ago
#3

I have updated this backport PR to apply the custom comment type approach for storage used in https://github.com/WordPress/gutenberg/pull/75549 which replaces the meta based approach in https://github.com/WordPress/gutenberg/issues/75144.

@adamsilverstein commented on PR #10930:


4 days ago
#4

Thanks for the review @t-hamano! I've pushed f3b5af251b addressing the feedback:

  • @since bumps: Updated all PR-introduced @since 7.0.0 to @since 7.1.0 (in comment.php, link-template.php, and class-wp-rest-comments-controller.php).
  • WP_Comment_Query: Updated the existing exclusion block to iterate over wp_get_internal_comment_types() so both note and reaction are excluded by default unless explicitly requested.
  • get_lastcommentmodified(): Added a comment_type NOT IN (…) clause built from wp_get_internal_comment_types() to all three timezone branches so internal comment types no longer affect the last modified date.
  • Reaction icon list: Moved wp_get_note_reaction_emojis() into WP_REST_Comments_Controller::get_note_reaction_emojis() as a protected static method, per your suggestion to avoid a public global while the icon-library plans are still being worked out.
  • wp_internal_comment_types filter: Removed — agreed it's not needed for an internal helper.
  • wp_list_pluck simplification at line 360: Applied. The 'note' === $comment->comment_type check inside the loop was redundant since $request['type'] is already gated to 'note' above and WP_Comment_Query constrains the result set, so it's gone too.

Locally, the relevant test suites (Tests_Comment_*, Tests_REST_Comments, Tests_Avatar) all pass: OK (165 tests, 476 assertions).

Note: See TracTickets for help on using tickets.