dfsdsf
This commit is contained in:
parent
9ae9b8da07
commit
6d3110ed15
17 changed files with 37 additions and 36 deletions
|
@ -143,7 +143,7 @@ def post_id(pid, anything=None, v=None):
|
|||
elif sort == "old":
|
||||
comments = comments.order_by(Comment.created_utc.asc())
|
||||
elif sort == "controversial":
|
||||
comments = comments.order_by(-1 * Comment.upvotes * (Comment.downvotes+1))
|
||||
comments = comments.order_by(-1 * Comment.upvotes * min(Comment.downvotes, 1))
|
||||
elif sort == "top":
|
||||
comments = comments.order_by(Comment.downvotes - Comment.upvotes)
|
||||
elif sort == "bottom":
|
||||
|
@ -168,7 +168,7 @@ def post_id(pid, anything=None, v=None):
|
|||
elif sort == "old":
|
||||
comments = comments.order_by(Comment.created_utc.asc())
|
||||
elif sort == "controversial":
|
||||
comments = comments.order_by(-1 * Comment.upvotes * (Comment.downvotes+1))
|
||||
comments = comments.order_by(-1 * Comment.upvotes * min(Comment.downvotes, 1))
|
||||
elif sort == "top":
|
||||
comments = comments.order_by(Comment.downvotes - Comment.upvotes)
|
||||
elif sort == "bottom":
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue