mirror of
https://github.com/solero/houdini.git
synced 2024-11-08 20:28:20 +00:00
Lower-case filter words automatically.
It's never specified that words must be lower case, make it fool-proof.
This commit is contained in:
parent
b4769d2383
commit
698104441a
@ -7,7 +7,7 @@ from houdini.handlers.play.moderation import moderator_ban
|
|||||||
|
|
||||||
@handlers.boot
|
@handlers.boot
|
||||||
async def filter_load(server):
|
async def filter_load(server):
|
||||||
server.chat_filter_words = await ChatFilterRuleCollection.get_collection()
|
server.chat_filter_words = {w.lower(): c for w, c in await ChatFilterRuleCollection.get_collection().items()}
|
||||||
server.logger.info(f'Loaded {len(server.chat_filter_words)} filter words')
|
server.logger.info(f'Loaded {len(server.chat_filter_words)} filter words')
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user