fix nsfw tagging
This commit is contained in:
parent
26f0411b66
commit
909cd67bef
1 changed files with 4 additions and 2 deletions
6
bot.py
6
bot.py
|
@ -138,11 +138,13 @@ if is_nsfw == False:
|
||||||
# Check if any config defined NSFW tags are present
|
# Check if any config defined NSFW tags are present
|
||||||
match config.type:
|
match config.type:
|
||||||
case "danbooru":
|
case "danbooru":
|
||||||
if tag in post["tag_string"] or tag in post["tag_string_general"] or tag in post["tag_string_artist"] or tag in post["tag_string_copyright"] or tag in post["tag_string_character"] or tag in post["tag_string_meta"]:
|
if tag in post["tag_string"].split():
|
||||||
|
print(tag)
|
||||||
is_nsfw = True
|
is_nsfw = True
|
||||||
break
|
break
|
||||||
case "gelbooru":
|
case "gelbooru":
|
||||||
if tag in post["tags"]:
|
if tag in post["tags"].split():
|
||||||
|
print(tag)
|
||||||
is_nsfw = True
|
is_nsfw = True
|
||||||
break
|
break
|
||||||
case _:
|
case _:
|
||||||
|
|
Loading…
Add table
Reference in a new issue