Skip to content

Commit

Permalink
Fix delete error
Browse files Browse the repository at this point in the history
  • Loading branch information
dyakovri committed Apr 15, 2024
1 parent 7657d44 commit 576eefb
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions social/handlers_telegram/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,5 +52,7 @@ async def validate_group(update: Update, context: CustomContext):
logger.info("Validation message received")
with db():
approve_telegram_group(update)
res = await update.effective_message.delete()
logger.info(f"Validation message handled, delete status = {res}")
try:
await update.effective_message.delete()
except Exception:
logger.exception("Failed to delete message")

0 comments on commit 576eefb

Please sign in to comment.