fix PEP-8 minors

This commit is contained in:
Martin Zimmermann 2013-10-24 11:56:48 +02:00
parent 4f5b247ed1
commit a8d0670db7
2 changed files with 2 additions and 6 deletions

View File

@ -32,7 +32,6 @@ dist = pkg_resources.get_distribution("isso")
import sys import sys
import os import os
import socket
from os.path import dirname, join from os.path import dirname, join
from argparse import ArgumentParser from argparse import ArgumentParser
@ -50,7 +49,7 @@ from werkzeug.contrib.fixers import ProxyFix
from jinja2 import Environment, FileSystemLoader from jinja2 import Environment, FileSystemLoader
from isso import db, migrate, views, wsgi, colors from isso import db, migrate, views, wsgi
from isso.core import NaiveMixin, uWSGIMixin, Config from isso.core import NaiveMixin, uWSGIMixin, Config
from isso.views import comment, admin from isso.views import comment, admin
@ -104,7 +103,7 @@ class Isso(object):
try: try:
handler, values = adapter.match() handler, values = adapter.match()
return handler(self, request.environ, request, **values) return handler(self, request.environ, request, **values)
except NotFound as e: except NotFound:
return Response('Not Found', 404) return Response('Not Found', 404)
except MethodNotAllowed: except MethodNotAllowed:
return Response("Yup.", 200) return Response("Yup.", 200)

View File

@ -58,9 +58,6 @@ class SMTPMailer(object):
self.from_addr = conf.get('SMTP', 'from') self.from_addr = conf.get('SMTP', 'from')
self.to_addr = conf.get('SMTP', 'to') self.to_addr = conf.get('SMTP', 'to')
with Connection(self.conf):
pass
def sendmail(self, subject, body): def sendmail(self, subject, body):
msg = MIMEText(body, 'plain', 'utf-8') msg = MIMEText(body, 'plain', 'utf-8')