diff --git a/vedia.rb b/vedia.rb index 80cb376..34c37dd 100644 --- a/vedia.rb +++ b/vedia.rb @@ -149,7 +149,7 @@ get '/reset' do end post '/reset' do - logger.info params[:email] + logger.info "Password reset request for \"#{params[:email]}\"" @errors = [] if not params[:email] =~ URI::MailTo::EMAIL_REGEXP @errors << OpenStruct.new(:attribute => :email, :type => :invalid) @@ -562,11 +562,11 @@ end def close_expired_votes Vote.where(state: 'open').where("expire_on < :now", { now: Time.now.utc }).each do |vote| - logger.info "#{Time.now.utc} Closing vote \"#{vote.title}\" because it expired on #{vote.expire_on}..." + puts "#{Time.now.utc} Closing vote \"#{vote.title}\" because it expired on #{vote.expire_on}..." vote.state = 'closed' vote.save User.all.each do |user| - logger.info "#{Time.now.utc} Sending results by email to #{user.email}..." + puts "#{Time.now.utc} Sending results by email to #{user.email}..." mail = Mail.new mail.from = settings.admin_email mail.to = user.email