mirror of
https://github.com/pirate/ArchiveBox.git
synced 2025-08-23 22:53:00 +02:00
Fix num_links missing in public index
This commit is contained in:
@@ -112,6 +112,11 @@ class PublicArchiveView(ListView):
|
|||||||
snapshot.icons = snapshot_icons(snapshot)
|
snapshot.icons = snapshot_icons(snapshot)
|
||||||
return qs
|
return qs
|
||||||
|
|
||||||
|
def get_context_data(self,**kwargs):
|
||||||
|
context = super(PublicArchiveView,self).get_context_data(**kwargs)
|
||||||
|
context['num_links'] = self.get_queryset().count()
|
||||||
|
return context
|
||||||
|
|
||||||
def get(self, *args, **kwargs):
|
def get(self, *args, **kwargs):
|
||||||
if PUBLIC_INDEX or self.request.user.is_authenticated:
|
if PUBLIC_INDEX or self.request.user.is_authenticated:
|
||||||
response = super().get(*args, **kwargs)
|
response = super().get(*args, **kwargs)
|
||||||
|
Reference in New Issue
Block a user