randydev commited on
Commit
3abaf09
·
verified ·
1 Parent(s): 460a580

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +6 -2
main.py CHANGED
@@ -67,12 +67,16 @@ async def user_status_ban(username: str = None):
67
  if user.status == ChatMemberStatus.BANNED:
68
  return {
69
  "message": f"❌ you {mention_user.first_name} have been blocked from the RendyProjects",
70
- "is_ban": True
 
71
  }
72
  return {
73
  "message": "User is not banned",
74
- "is_ban": False
 
75
  }
 
 
76
  except UserNotParticipant:
77
  return False
78
 
 
67
  if user.status == ChatMemberStatus.BANNED:
68
  return {
69
  "message": f"❌ you {mention_user.first_name} have been blocked from the RendyProjects",
70
+ "is_ban": True,
71
+ "user_id": mention_user.id
72
  }
73
  return {
74
  "message": "User is not banned",
75
+ "is_ban": False,
76
+ "user_id": mention_user.id
77
  }
78
+ except PeerIdInvalid:
79
+ return False
80
  except UserNotParticipant:
81
  return False
82