refactor sqlite queue
This commit is contained in:
@@ -163,6 +163,6 @@ func (q *Queue) Stop() {
|
||||
q.stop = true
|
||||
// Wait for all emails to be processed
|
||||
q.wg.Wait()
|
||||
// Close the email queue
|
||||
// Stop the email queue
|
||||
close(q.emailQueue)
|
||||
}
|
||||
|
||||
@@ -22,7 +22,7 @@ func TestEmailQueue(t *testing.T) {
|
||||
}
|
||||
queue.AddEmail(email)
|
||||
}
|
||||
// Close the queue after all emails are processed
|
||||
// Stop the queue after all emails are processed
|
||||
queue.Stop()
|
||||
|
||||
assert.Equal(t, queue.FailedSendCount, 0)
|
||||
|
||||
Reference in New Issue
Block a user