Add a notification setting for likes, reposts and quotes - #3582
Open
pfefferle wants to merge 3 commits into
Open
Add a notification setting for likes, reposts and quotes#3582pfefferle wants to merge 3 commits into
pfefferle wants to merge 3 commits into
Conversation
There was a problem hiding this comment.
Pull request overview
Adds a per-user notification toggle to suppress WordPress “new comment” emails for ActivityPub reaction comments (likes/reposts/quotes) while leaving normal replies unaffected, addressing #3578.
Changes:
- Introduces a new user option (
activitypub_mailer_new_reaction) with a default “on” behavior. - Adds a new checkbox in the user’s ActivityPub “Email Notifications” settings and persists it on save.
- Updates comment-notification suppression logic and adds PHPUnit coverage for the new behavior.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
includes/class-mailer.php |
Applies the new per-user setting when deciding whether to send comment-notification emails. |
includes/class-activitypub.php |
Registers the new user meta and default behavior via get_user_option_* filter. |
includes/wp-admin/class-user-settings-fields.php |
Adds the “Likes, Reposts and Quotes” checkbox to the profile notification settings UI. |
includes/wp-admin/class-admin.php |
Persists the new user option on settings save. |
tests/phpunit/tests/includes/class-test-mailer.php |
Adds a unit test for the new reaction notification behavior. |
.github/changelog/add-reaction-email-setting |
Documents the new notification setting in the changelog. |
Member
Author
|
Thanks, all three are addressed in 1b06ab0:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #3578
Proposed changes:
Other information:
Testing instructions:
Changelog entry
The changelog entry is already included in the branch (
.github/changelog/add-reaction-email-setting), so the auto-create box below is left unchecked.Changelog Entry Details
Significance
Type
Message
Add a notification setting to turn off emails about likes and reposts without silencing real comments and replies.