mirror of
https://github.com/solero/houdini.git
synced 2024-11-22 05:27:23 +00:00
Merge pull request #74 from floogal/patch-1
This commit is contained in:
commit
a8fc63393e
@ -2,7 +2,7 @@ from houdini import handlers
|
|||||||
from houdini.commands import UnknownCommandException, has_command_prefix, invoke_command_string
|
from houdini.commands import UnknownCommandException, has_command_prefix, invoke_command_string
|
||||||
from houdini.data.moderator import ChatFilterRuleCollection
|
from houdini.data.moderator import ChatFilterRuleCollection
|
||||||
from houdini.handlers import XTPacket
|
from houdini.handlers import XTPacket
|
||||||
from houdini.handlers.play.moderation import moderator_ban
|
from houdini.handlers.play.moderation import moderator_ban, moderator_kick
|
||||||
|
|
||||||
|
|
||||||
@handlers.boot
|
@handlers.boot
|
||||||
@ -32,7 +32,10 @@ async def handle_send_message(p, penguin_id: int, message: str):
|
|||||||
if consequence.ban:
|
if consequence.ban:
|
||||||
await moderator_ban(p, p.id, comment='Inappropriate language', message=message)
|
await moderator_ban(p, p.id, comment='Inappropriate language', message=message)
|
||||||
return
|
return
|
||||||
if consequence.filter:
|
if consequence.warn:
|
||||||
|
await moderator_kick(p, p.id)
|
||||||
|
return
|
||||||
|
else:
|
||||||
return
|
return
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
Loading…
Reference in New Issue
Block a user