fd
This commit is contained in:
parent
acd240f02a
commit
ec20085f3e
2 changed files with 5 additions and 1 deletions
|
@ -348,6 +348,8 @@ class Submission(Base):
|
||||||
def realbody(self, v):
|
def realbody(self, v):
|
||||||
if self.club and not (v and (v.paid_dues or v.id == self.author_id)): return f"<p>{cc} ONLY</p>"
|
if self.club and not (v and (v.paid_dues or v.id == self.author_id)): return f"<p>{cc} ONLY</p>"
|
||||||
|
|
||||||
|
if not body_html: return ""
|
||||||
|
|
||||||
body = self.body_html
|
body = self.body_html
|
||||||
body = censor_slurs(body, v)
|
body = censor_slurs(body, v)
|
||||||
|
|
||||||
|
@ -375,6 +377,8 @@ class Submission(Base):
|
||||||
def plainbody(self, v):
|
def plainbody(self, v):
|
||||||
if self.club and not (v and (v.paid_dues or v.id == self.author_id)): return f"<p>{cc} ONLY</p>"
|
if self.club and not (v and (v.paid_dues or v.id == self.author_id)): return f"<p>{cc} ONLY</p>"
|
||||||
|
|
||||||
|
if not body: return ""
|
||||||
|
|
||||||
body = self.body
|
body = self.body
|
||||||
body = censor_slurs(body, v)
|
body = censor_slurs(body, v)
|
||||||
|
|
||||||
|
|
|
@ -60,7 +60,7 @@ def get_user(username, v=None, graceful=False):
|
||||||
UserBlock.target_id == v.id
|
UserBlock.target_id == v.id
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
).one_or_none()
|
).first()
|
||||||
|
|
||||||
user.is_blocking = block and block.user_id == v.id
|
user.is_blocking = block and block.user_id == v.id
|
||||||
user.is_blocked = block and block.target_id == v.id
|
user.is_blocked = block and block.target_id == v.id
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue