summaryrefslogtreecommitdiff
path: root/mirrors/views.py
diff options
context:
space:
mode:
Diffstat (limited to 'mirrors/views.py')
-rw-r--r--mirrors/views.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/mirrors/views.py b/mirrors/views.py
index 59d6337b..b13c9148 100644
--- a/mirrors/views.py
+++ b/mirrors/views.py
@@ -78,7 +78,10 @@ def status(request):
error_count=Count('error'), last_occurred=Max('check_time')
).order_by('-last_occurred', '-error_count')
- last_check = max([u.last_check for u in urls])
+ if urls:
+ last_check = max([u.last_check for u in urls])
+ else:
+ last_check = None
good_urls = []
bad_urls = []