From a4dbe81aa1fcf2f810a1824951bd5a9ed0c98163 Mon Sep 17 00:00:00 2001 From: McBrayer Date: Tue, 29 Jan 2019 13:06:04 -0500 Subject: [PATCH] Add id targets to redirects from boost/fav without JS. Resolves #48 --- brutaldon/views.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/brutaldon/views.py b/brutaldon/views.py index d9298ca..7e154e4 100644 --- a/brutaldon/views.py +++ b/brutaldon/views.py @@ -686,7 +686,7 @@ def fav(request, id): 'own_acct': request.session['user'], "preferences": account.preferences}) else: - return redirect(thread, id) + return HttpResponseRedirect(reverse('thread', args=[id]) + "#toot-"+str(id)) else: return render(request, 'main/fav.html', {"toot": toot, @@ -712,7 +712,7 @@ def boost(request, id): 'own_acct': request.session['user'], "preferences": account.preferences}) else: - return redirect(thread, id) + return HttpResponseRedirect(reverse('thread', args=[id]) + "#toot-"+str(id)) else: return render(request, 'main/boost.html', {"toot": toot,