From 10fcc82fbf49ea75330ffb308c543d169b91efe5 Mon Sep 17 00:00:00 2001 From: f Date: Mon, 26 Feb 2018 21:03:10 -0300 Subject: [PATCH] no usar el servidor imap del correo --- .env.example | 1 + lib/warden/imap.rb | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.env.example b/.env.example index 1cca08ad..9c5d13f5 100644 --- a/.env.example +++ b/.env.example @@ -1 +1,2 @@ SECRET_KEY_BASE= +IMAP_SERVER= diff --git a/lib/warden/imap.rb b/lib/warden/imap.rb index e757ca1c..a17ce5ad 100644 --- a/lib/warden/imap.rb +++ b/lib/warden/imap.rb @@ -26,7 +26,7 @@ module Warden def imap_connect # No vamos a enviar la contraseña en texto plano a ningún lado - @imap = Net::IMAP.new(@email.host_name, ssl: true) + @imap = Net::IMAP.new(ENV.fetch('IMAP_SERVER', 'kefir.red'), ssl: true) # Errores más comunes según # https://ruby-doc.org/stdlib-2.0.0/libdoc/net/imap/rdoc/Net/IMAP.html rescue Errno::ECONNREFUSED, Errno::ETIMEDOUT, Errno::ENETUNREACH,