File size: 258 Bytes
155c78b
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
import re

def is_blocked_markdown_code(message):
    pattern = r"(?:python|py|javascript|js|bash|sh|html|go|cpp|c|json)\n.*?"
    match = re.search(pattern, message, re.DOTALL | re.IGNORECASE)
    if match:
        return True
    else:
        return False