GroupButler icon indicating copy to clipboard operation
GroupButler copied to clipboard

Warning sent twice

Open RememberTheAir opened this issue 9 years ago • 2 comments

1 - Sending a photo with a telegram.me link in the caption or forwarding a photo from a channel result in a double warn, if telegram.me links or messages from channels (antispam) and photos (media) are both forbidden in the chat.


2 - Also, if a message is forwarded from a channel and has a telegram.me link in the caption, msg.spam will contain "links" string. Could be a possible issue if in a group only forwards from channels are forbidden: a message like that will trigger only the telegram.me links block

RememberTheAir avatar Nov 05 '16 13:11 RememberTheAir

Problem n° 2 - msg.spam should be an array of strings

RememberTheAir avatar Nov 05 '16 13:11 RememberTheAir

The problem is that the spam check is made before on_msg_receive is called, in bot.lua I don't want to query redis before that funtion, but it seems to be the only way to fix this, yes

RememberTheAir avatar Nov 11 '16 13:11 RememberTheAir