From c4c3117caae8947f3529a82e27b17759e3bd0a11 Mon Sep 17 00:00:00 2001 From: McBrayer Date: Tue, 29 Jan 2019 13:38:07 -0500 Subject: [PATCH] After submitting a reply, jump right to the message you are replying to. --- brutaldon/views.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/brutaldon/views.py b/brutaldon/views.py index 7e154e4..e0aafc1 100644 --- a/brutaldon/views.py +++ b/brutaldon/views.py @@ -659,14 +659,15 @@ def reply(request, id): 'own_acct': request.session['user'], 'notifications': notifications, 'preferences': account.preferences}) - return redirect(thread, id) + return HttpResponseRedirect(reverse('thread', args=[id]) + "#toot-"+str(id)) else: return render(request, 'main/reply.html', {'context': context, 'toot': toot, 'form': form, 'reply': True, 'own_acct': request.session['user'], 'preferences': account.preferences}) else: - return redirect(reply, id) + return HttpResponseRedirect(reverse('reply', args=[id]) + "#toot-"+str(id)) + @never_cache @br_login_required