Skip to content

Commit

Permalink
[#1635] Fix handling of smtp.starttls option
Browse files Browse the repository at this point in the history
  • Loading branch information
Sean Hammond committed Dec 4, 2012
1 parent 4cb0277 commit b29c28f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion ckan/lib/mailer.py
Expand Up @@ -11,6 +11,7 @@
from pylons import config
from ckan import model, __version__
from ckan.lib.helpers import url_for
import paste.deploy.converters

log = logging.getLogger(__name__)

Expand Down Expand Up @@ -48,7 +49,8 @@ def _mail_recipient(recipient_name, recipient_email,
smtp_password = None
else:
smtp_server = config.get('smtp.server', 'localhost')
smtp_starttls = config.get('smtp.starttls')
smtp_starttls = paste.deploy.converters.asbool(
config.get('smtp.starttls'))
smtp_user = config.get('smtp.user')
smtp_password = config.get('smtp.password')
smtp_connection.connect(smtp_server)
Expand Down

0 comments on commit b29c28f

Please sign in to comment.