Show More
@@ -1,6 +1,8 b'' | |||
|
1 | 1 | from django.core.files import File |
|
2 | 2 | from django.core.files.temp import NamedTemporaryFile |
|
3 | from django.core.paginator import EmptyPage | |
|
3 | 4 | from django.db import transaction |
|
5 | from django.http import Http404 | |
|
4 | 6 | from django.shortcuts import render, redirect |
|
5 | 7 | import requests |
|
6 | 8 | |
@@ -46,7 +48,10 b' class AllThreadsView(PostMixin, BaseBoar' | |||
|
46 | 48 | settings.THREADS_PER_PAGE) |
|
47 | 49 | paginator.current_page = int(page) |
|
48 | 50 | |
|
49 | threads = paginator.page(page).object_list | |
|
51 | try: | |
|
52 | threads = paginator.page(page).object_list | |
|
53 | except EmptyPage: | |
|
54 | raise Http404() | |
|
50 | 55 | |
|
51 | 56 | params[PARAMETER_THREADS] = threads |
|
52 | 57 | params[CONTEXT_FORM] = form |
General Comments 0
You need to be logged in to leave comments.
Login now