When liking a post, now forwards to same page you liked from
This commit is contained in:
parent
d674bc7acf
commit
8fc41c2d0e
1 changed files with 2 additions and 2 deletions
|
@ -196,7 +196,7 @@ def like_post(post_id):
|
|||
logged_in = session['username']
|
||||
if request.method == "POST":
|
||||
timeline.like_post(post_id, logged_in)
|
||||
return redirect(str('/view/' + post_id))
|
||||
return redirect(request.referrer)
|
||||
elif request.method == "GET":
|
||||
pass
|
||||
|
||||
|
@ -206,7 +206,7 @@ def unlike_post(post_id):
|
|||
logged_in = session['username']
|
||||
if request.method == "POST":
|
||||
timeline.unlike_post(post_id, logged_in)
|
||||
return redirect(str('/view/' + post_id))
|
||||
return redirect(request.referrer)
|
||||
elif request.method == "GET":
|
||||
pass
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue