diff --git a/src/postorius/context_processors.py b/src/postorius/context_processors.py index 035f307..213f68c 100644 --- a/src/postorius/context_processors.py +++ b/src/postorius/context_processors.py @@ -19,11 +19,6 @@ from __future__ import absolute_import, unicode_literals import logging - -from django.conf import settings -from django.core.urlresolvers import reverse, NoReverseMatch -from django.shortcuts import resolve_url - logger = logging.getLogger(__name__) diff --git a/src/postorius/urls.py b/src/postorius/urls.py index d921571..06f4347 100644 --- a/src/postorius/urls.py +++ b/src/postorius/urls.py @@ -19,8 +19,6 @@ from __future__ import absolute_import, unicode_literals from django.conf.urls import url, include -from django.contrib.auth.views import login as login_view -from django.contrib.auth.views import logout as logout_view from postorius.views import list as list_views from postorius.views import user as user_views diff --git a/src/postorius/views/user.py b/src/postorius/views/user.py index 49daf94..50420db 100644 --- a/src/postorius/views/user.py +++ b/src/postorius/views/user.py @@ -19,6 +19,10 @@ from __future__ import absolute_import, unicode_literals import logging +try: + from urllib2 import HTTPError +except ImportError: + from urllib.error import HTTPError from allauth.account.models import EmailAddress from django.forms import formset_factory @@ -28,23 +32,12 @@ from django.utils.decorators import method_decorator from django.utils.translation import gettext as _ from django.http import Http404 -from django.core.urlresolvers import reverse -from django.conf import settings - -try: - from urllib2 import HTTPError -except ImportError: - from urllib.error import HTTPError from postorius import utils from postorius.models import ( MailmanApiError, List, MailmanUser, Mailman404Error) from postorius.forms import UserPreferences, ChangeSubscriptionForm from postorius.views.generic import MailmanUserView -from smtplib import SMTPException -from socket import error as socket_error -import errno -import uuid logger = logging.getLogger(__name__)