euscanwww: removing unused import and PEP8 cleaning

Signed-off-by: volpino <fox91@anche.no>
This commit is contained in:
volpino 2012-07-29 10:13:17 +02:00
parent a88824309d
commit 6178d66f0d
3 changed files with 5 additions and 4 deletions

View File

@ -13,6 +13,7 @@ from euscan.version import get_version_type
from djeuscan.processing import FakeLogger from djeuscan.processing import FakeLogger
from djeuscan.models import Package, Version, VersionLog, Category, Overlay from djeuscan.models import Package, Version, VersionLog, Category, Overlay
class ScanPortage(object): class ScanPortage(object):
def __init__(self, logger=None, no_log=False, purge_packages=False, def __init__(self, logger=None, no_log=False, purge_packages=False,
purge_versions=False): purge_versions=False):

View File

@ -2,9 +2,9 @@
import threading import threading
from django.conf import settings
from django.core.mail.backends.base import BaseEmailBackend from django.core.mail.backends.base import BaseEmailBackend
from subprocess import Popen,PIPE from subprocess import Popen, PIPE
class EmailBackend(BaseEmailBackend): class EmailBackend(BaseEmailBackend):
def __init__(self, fail_silently=False, **kwargs): def __init__(self, fail_silently=False, **kwargs):
@ -40,7 +40,7 @@ class EmailBackend(BaseEmailBackend):
if not email_message.recipients(): if not email_message.recipients():
return False return False
try: try:
ps = Popen(["sendmail"]+list(email_message.recipients()), \ ps = Popen(["sendmail"] + list(email_message.recipients()), \
stdin=PIPE) stdin=PIPE)
ps.stdin.write(email_message.message().as_string()) ps.stdin.write(email_message.message().as_string())
ps.stdin.flush() ps.stdin.flush()