Fixed not passing the logged user to the censor

This commit is contained in:
Yo Mama 2021-10-16 20:56:12 +02:00
parent 0de6608408
commit 4cc5a554d4
4 changed files with 26 additions and 26 deletions

View file

@ -47,8 +47,8 @@ def sub_matcher(match: Match):
return (match.group(1) or '') + replacer + (match.group(4) or '')
def censor_slurs(v, body: str):
if v and not v.slurreplacer:
def censor_slurs(body: str, logged_user):
if logged_user and not logged_user.slurreplacer:
return body
for (slur, replace) in SLURS.items():