Skip to content

Commit 4709ea6

Browse files
committed
Remove SupportView because it's not needed
It was there only because of `support_email`, but that variable was not used in the template at all.
1 parent ed0e4a0 commit 4709ea6

File tree

2 files changed

+1
-17
lines changed

2 files changed

+1
-17
lines changed

readthedocs/core/views/__init__.py

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -45,21 +45,6 @@ def get_context_data(self, **kwargs):
4545
return context
4646

4747

48-
class SupportView(TemplateView):
49-
template_name = 'support.html'
50-
51-
def get_context_data(self, **kwargs):
52-
context = super().get_context_data(**kwargs)
53-
support_email = settings.SUPPORT_EMAIL
54-
if not support_email:
55-
support_email = 'support@{domain}'.format(
56-
domain=settings.PRODUCTION_DOMAIN
57-
)
58-
59-
context['support_email'] = support_email
60-
return context
61-
62-
6348
def wipe_version(request, project_slug, version_slug):
6449
version = get_object_or_404(
6550
Version.internal.all(),

readthedocs/urls.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
from readthedocs.core.urls import core_urls, docs_urls
1313
from readthedocs.core.views import (
1414
HomepageView,
15-
SupportView,
1615
do_not_track,
1716
server_error_404,
1817
server_error_500,
@@ -28,7 +27,7 @@
2827

2928
basic_urls = [
3029
url(r'^$', HomepageView.as_view(), name='homepage'),
31-
url(r'^support/', SupportView.as_view(), name='support'),
30+
url(r'^support/', TemplateView.as_view(template_name='support.html'), name='support'),
3231
url(r'^security/', TemplateView.as_view(template_name='security.html')),
3332
url(
3433
r'^\.well-known/security.txt$',

0 commit comments

Comments
 (0)