Compare commits
No commits in common. "fa54d641cc415154cab7a780ac9f9387dbdf720e" and "3fc088c938bf60da4e2d5f445976d1d3fda8a92e" have entirely different histories.
fa54d641cc
...
3fc088c938
|
@ -20,4 +20,3 @@ config:
|
|||
log_reports: true
|
||||
log_forwards: true
|
||||
log_ring_maxlen: 69420
|
||||
auto_clear_reactions: false
|
||||
|
|
|
@ -1,15 +0,0 @@
|
|||
import asyncio
|
||||
from pyrogram import Client, filters
|
||||
from pyrogram.raw.functions.messages import ReadReactions
|
||||
from .. import config, log_errors
|
||||
|
||||
# I fucking HATE reactions!
|
||||
@Client.on_message(filters.outgoing & filters.edited)
|
||||
@log_errors
|
||||
async def auto_clear_reactions(client, message):
|
||||
if not config['config'].get('auto_clear_reactions') or not message.reactions:
|
||||
return
|
||||
while True:
|
||||
if (await client.send(ReadReactions(peer=await client.resolve_peer(message.chat.id)))).pts_count > 0:
|
||||
break
|
||||
await asyncio.sleep(1)
|
|
@ -16,7 +16,10 @@ PYEXEC_REGEX = '^(?:' + '|'.join(map(re.escape, config['config']['prefixes'])) +
|
|||
@log_errors
|
||||
@public_log_errors
|
||||
async def pyexec(client, message):
|
||||
code = message.matches[0].group(1).strip()
|
||||
match = re.match(PYEXEC_REGEX, (message.text or message.caption).markdown)
|
||||
if not match:
|
||||
return
|
||||
code = match.group(1).strip()
|
||||
class UniqueExecReturnIdentifier:
|
||||
pass
|
||||
tree = ast.parse(code)
|
||||
|
|
Loading…
Reference in New Issue