Download & Extend

newsletter send status should be updated on cron after the send() function and the clear_spool() function

Project:Simplenews
Version:6.x-1.x-dev
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed (fixed)

Issue Summary

I noticed that I had an empty email accidentally stored in my subscription table which leaked to the spool table, and that message was never being removed from the spool (probably it would after expiring).

I removed it manually and noticed the newsletter status was not properly set to sent although the spool was empty. I checked the code, and the status was only being updated when there were actual messages to sent, but the clear spool function can also clear rows from that table, so I think it's better to have the update status be run on the _cron() hook after the other two.

Attached is a patch for that.

AttachmentSizeStatusTest resultOperations
simplenews_updatastatusoncron.patch796 bytesIgnored: Check issue status.NoneNone

Comments

#1

Status:needs review» fixed

Patch committed, thanks for the improvement. Fixes will be available in the next 1.x and 2.x dev releases.

#2

Status:fixed» closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

nobody click here