remotes/1693045480750635534/spooky-22
Aevann1 2021-12-14 20:35:56 +02:00
parent 3a9b1ecb3e
commit 98b6cc7f22
3 changed files with 4 additions and 3 deletions

View File

@ -265,14 +265,14 @@ class Comment(Base):
data= {'is_banned': True,
'ban_reason': self.ban_reason,
'id': self.id,
'post': self.post.id,
'post': self.post.id if self.post else 0,
'level': self.level,
'parent': self.parent_fullname
}
elif self.deleted_utc > 0:
data= {'deleted_utc': self.deleted_utc,
'id': self.id,
'post': self.post.id,
'post': self.post.id if self.post else 0,
'level': self.level,
'parent': self.parent_fullname
}

View File

@ -105,6 +105,7 @@ def notifications(v):
if c not in listing:
listing.append(c)
if request.headers.get("Authorization"): return {"data":[x.json for x in listing]}
return render_template("notifications.html",
v=v,

View File

@ -249,7 +249,7 @@ def searchcomments(v):
comments = get_comments(ids, v=v)
if request.headers.get("Authorization"): return [x.json for x in comments]
if request.headers.get("Authorization"): return {"data":[x.json for x in comments]}
else: return render_template("search_comments.html", v=v, query=query, total=total, page=page, comments=comments, sort=sort, t=t, next_exists=next_exists)