From d6e153bfdfc6e619e21f4b0d2e355d32ab298817 Mon Sep 17 00:00:00 2001 From: Aditya Anand M C Date: Wed, 27 Nov 2019 16:19:03 +0530 Subject: [PATCH] feat: redirect to hackathon list for incorrect URL (#5552) --- app/dashboard/views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/dashboard/views.py b/app/dashboard/views.py index 0e52d373b5a..260ac97a7db 100644 --- a/app/dashboard/views.py +++ b/app/dashboard/views.py @@ -3418,7 +3418,7 @@ def hackathon(request, hackathon=''): try: hackathon_event = HackathonEvent.objects.filter(slug__iexact=hackathon).latest('id') except HackathonEvent.DoesNotExist: - hackathon_event = HackathonEvent.objects.last() + return redirect(reverse('get_hackathons')) title = hackathon_event.name network = get_default_network()