lib/mail_spy/manager.rb in mail_spy-0.0.6 vs lib/mail_spy/manager.rb in mail_spy-0.0.7
- old
+ new
@@ -84,10 +84,10 @@
while true
emails = MailSpy::Email.
limit(step).offset(offset).
where(:schedule_at.lte => DateTime.now, :sent => false, :failed => false).all
- break if mails.blank?
+ break if emails.blank?
emails.each do |email|
begin
mail = MailSpy::CoreMailer.template(email)
#TODO might be nice to flush mail out in debug mode
mail.deliver