dffd
This commit is contained in:
parent
4aff935c8b
commit
aa09a41543
3 changed files with 3 additions and 5 deletions
|
@ -130,8 +130,7 @@ class Submission(Base, Stndrd, Age_times, Scores, Fuzzing):
|
|||
|
||||
output = '-'.join(output)
|
||||
|
||||
if not output:
|
||||
output = '-'
|
||||
if not output: output = '-'
|
||||
|
||||
return f"/post/{self.id}/{output}"
|
||||
|
||||
|
|
|
@ -77,7 +77,6 @@ def remove_report(report_fn, v):
|
|||
else:
|
||||
return {"error": "Invalid report ID"}, 400
|
||||
|
||||
_response = f"Removed @{report.user.username}'s report"
|
||||
g.db.delete(report)
|
||||
|
||||
return {"message": _response}, 200
|
||||
return {"message": "Removed report"}
|
|
@ -367,7 +367,7 @@ def random_post(v):
|
|||
n = random.randint(0, total - 1)
|
||||
|
||||
post = x.offset(n).limit(1).first()
|
||||
return redirect(post.permalink)
|
||||
return redirect(f"/post/{post.id}")
|
||||
|
||||
@cache.memoize(timeout=86400)
|
||||
def comment_idlist(page=1, v=None, nsfw=False, sort="new", t="all", **kwargs):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue