1
0
Fork 0

Force authorization for all routes

This commit is contained in:
Dariusz Niemczyk 2023-07-13 21:01:00 +02:00
parent b74c1b3c8f
commit a8f7530263
No known key found for this signature in database
1 changed files with 3 additions and 0 deletions

View File

@ -58,6 +58,7 @@ def apply_smart_search(query, objects):
return objects return objects
@login_required
def index(request): def index(request):
# get_roots was removed, so we're doing it this way now. # get_roots was removed, so we're doing it this way now.
return render( return render(
@ -65,6 +66,7 @@ def index(request):
) )
@login_required
def search(request): def search(request):
query = request.GET.get("q", "") query = request.GET.get("q", "")
@ -83,6 +85,7 @@ def search(request):
) )
@login_required
def item_display(request, pk): def item_display(request, pk):
if not pk: if not pk:
return index(request) return index(request)