fix: user deletion reminder emails counting up

Resolves #1014
This commit is contained in:
kolaente 2021-12-12 12:24:42 +01:00
parent 72d3c54efd
commit f581885e65
No known key found for this signature in database
GPG key ID: F40E70337AB24C9B

View file

@ -58,10 +58,10 @@ func notifyUsersScheduledForDeletion() {
var number = 2
if user.DeletionLastReminderSent.IsZero() {
number = 1
number = 3
}
if user.DeletionScheduledAt.Sub(user.DeletionLastReminderSent) < time.Hour*24 {
number = 3
number = 1
}
log.Debugf("Notifying user %d of the deletion of their account...", user.ID)