Skip to content

AO3-5696 fix orphan account chapter subscription emails#5758

Open
pmonfort wants to merge 2 commits intootwcode:masterfrom
pmonfort:AO3-5696-fix-orphan-account-chapter-subscription-emails
Open

AO3-5696 fix orphan account chapter subscription emails#5758
pmonfort wants to merge 2 commits intootwcode:masterfrom
pmonfort:AO3-5696-fix-orphan-account-chapter-subscription-emails

Conversation

@pmonfort
Copy link
Copy Markdown
Contributor

Issue

https://otwarchive.atlassian.net/browse/AO3-5696

Purpose

When orphan_account is a co-creator on a multi-chapter work and another co-creator posts a new chapter without listing orphan_account, users subscribed to orphan_account incorrectly receive subscription emails.

The existing check in Subscription#valid_notification_entry? only inspects the creation's (chapter's) pseuds, missing the case where orphan_account is a co-creator at the work level but not on the individual chapter.

Added a guard that skips notifications when the subscription is to orphan_account directly. Subscribers of other co-creators on the same work are not affected.

Testing Instructions

  1. Subscribe to orphan_account
  2. Create a work with orphan_account as co-creator
  3. Post a new chapter without adding orphan_account as chapter co-creator
  4. Run bundle exec rake notifications:deliver_subscriptions
  5. Verify no subscription email is sent to the subscriber of orphan_account
  6. Verify that subscribers of the other co-creator still receive emails

References

Related to AO3-3620 (Allow subscriptions to orphan_account to receive notifications). When AO3-3620 is fixed, the two
User.orphan_account guards in valid_notification_entry? should be removed.

Credit

Pablo Monfort (he/him)

@sarken sarken changed the title Ao3 5696 fix orphan account chapter subscription emails AO3-5696 fix orphan account chapter subscription emails Apr 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant