Skip to content

Cron removes Simplenews subscriptions for blocked users #86

@amilenkov

Description

@amilenkov

After upgrading Simplenews from 1.x-1.2.1 to 1.x-1.2.3, running cron unsubscribes/removes newsletter subscriptions associated with blocked user accounts created through Ubercart checkout.

The user accounts themselves remain present and blocked. Only the Simplenews subscriptions are affected.

This behavior appears even when simplenews_rules is disabled.

I would like to suggest making the relation between newsletter subscription status and user account status configurable.


Environment

  • Backdrop CMS: latest stable version
  • Ubercart enabled
  • Simplenews upgraded from 1.x-1.2.11.x-1.2.3
  • simplenews_rules module disabled
  • One newsletter list
  • About 918 active subscribers before cron

Steps to reproduce

  1. Install/enable Ubercart and Simplenews.
  2. Enable anonymous checkout in Ubercart.
  3. Allow newsletter subscriptions during checkout.
  4. Complete orders using guest/temporary customer accounts that later become blocked users.
  5. Upgrade Simplenews from 1.x-1.2.1 to 1.x-1.2.3.
  6. Run database updates.
  7. Run cron manually.

Actual result

After cron:

  • active subscribers dropped from 918 to 222
  • subscriptions associated with blocked user accounts were removed/unsubscribed
  • blocked user accounts themselves remained present in the users list
  • subscriptions belonging to active users (for example administrator accounts) remained intact
  • subscriptions created through the public newsletter subscription form by visitors without user accounts also remained intact

The issue occurs even with simplenews_rules disabled.


Expected result

Blocked user accounts should not automatically lose newsletter subscriptions unless this behavior is explicitly configured by the site administrator.

Many real stores intentionally keep newsletter subscriptions for customers whose accounts are blocked or inactive, because the subscription represents marketing consent tied to the email address, not necessarily to the current user account status.


Additional notes

Version 1.x-1.2.1 does not show this behavior on the same site and database.

The issue became visible only after upgrading and running cron.

I currently reverted the production site back to 1.x-1.2.1.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions