Skip to content

Extend inactive subscriber deletion to include unsubscribed status - #97

Merged
katsar0v merged 3 commits into
mainfrom
claude/fix-delete-subscribers-button-yi1xN
Mar 8, 2026
Merged

Extend inactive subscriber deletion to include unsubscribed status#97
katsar0v merged 3 commits into
mainfrom
claude/fix-delete-subscribers-button-yi1xN

Conversation

@katsar0v

@katsar0v katsar0v commented Mar 8, 2026

Copy link
Copy Markdown
Owner

Summary

Updated the subscriber deletion feature to include unsubscribed subscribers in addition to inactive (unconfirmed) subscribers. This change affects the database query, user-facing messages, and documentation strings across the codebase.

Key Changes

  • Database Query: Modified delete_inactive() method in class-subscriber-service.php to query for subscribers with either inactive OR unsubscribed status instead of just inactive
  • User Messages: Updated confirmation dialogs, success messages, and help text to reflect that both inactive and unsubscribed subscribers will be deleted
  • Documentation: Updated method docstrings and comments to accurately describe the expanded functionality
  • Localization: Updated translation strings in Bulgarian (bg_BG) and German (de_DE) language files to match the new messaging

Implementation Details

  • The SQL query now uses WHERE status IN (%s, %s) with both 'inactive' and 'unsubscribed' values
  • All user-facing strings were updated consistently across settings UI, AJAX handlers, and confirmation dialogs
  • Plural form handling in success messages was preserved for both singular and plural cases
  • Binary translation files (.mo) were regenerated to match the updated source strings

https://claude.ai/code/session_01YHiwtqwU8em5guVPZA2ikB

claude added 3 commits March 8, 2026 16:34
The "delete inactive subscribers" button now also deletes subscribers
with 'unsubscribed' status, in addition to 'inactive' (unconfirmed).
Updated SQL query, success/empty messages, button description, and
confirmation dialog to reflect the expanded scope.

https://claude.ai/code/session_01YHiwtqwU8em5guVPZA2ikB
Updated Bulgarian (bg_BG) and German (de_DE) .po and .mo files to reflect
the new msgid strings and translated descriptions/messages for the expanded
delete action that now covers inactive, unconfirmed, and unsubscribed subscribers.

https://claude.ai/code/session_01YHiwtqwU8em5guVPZA2ikB
- MO files: Recompile using wp i18n make-mo (WP-CLI) to match exact
  binary output expected by the Translations CI check
- PHP 8.1 tests: Fix undefined variable $class (should be $class_name)
  in test bootstrap autoloader; PHP 8.1 converts undefined variable
  warnings to exceptions via convertWarningsToExceptions in phpunit.xml
- CHANGELOG: Add entry for the delete unsubscribed subscribers change
  and the bootstrap fix

https://claude.ai/code/session_01YHiwtqwU8em5guVPZA2ikB
@katsar0v
katsar0v merged commit e8dfba3 into main Mar 8, 2026
6 checks passed
@katsar0v
katsar0v deleted the claude/fix-delete-subscribers-button-yi1xN branch March 8, 2026 16:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants