Spaces:
Paused
Paused
Captain Ezio
commited on
Commit
·
7e187ce
1
Parent(s):
037d703
Update admin.py
Browse files- Powers/plugins/admin.py +7 -7
Powers/plugins/admin.py
CHANGED
|
@@ -183,7 +183,7 @@ async def fullpromote_usr(c: Gojo, m: Message):
|
|
| 183 |
await m.reply_text("Huh, how can I even promote myself?")
|
| 184 |
return
|
| 185 |
|
| 186 |
-
if not bot.can_promote_members:
|
| 187 |
return await m.reply_text(
|
| 188 |
"I don't have enough permissions!",
|
| 189 |
) # This should be here
|
|
@@ -300,7 +300,7 @@ async def promote_usr(c: Gojo, m: Message):
|
|
| 300 |
await m.reply_text("Huh, how can I even promote myself?")
|
| 301 |
return
|
| 302 |
|
| 303 |
-
if not bot.can_promote_members:
|
| 304 |
return await m.reply_text(
|
| 305 |
"I don't have enough permissions",
|
| 306 |
) # This should be here
|
|
@@ -396,7 +396,7 @@ async def get_invitelink(c: Gojo, m: Message):
|
|
| 396 |
if m.from_user.id not in DEV_LEVEL:
|
| 397 |
user = await m.chat.get_member(m.from_user.id)
|
| 398 |
|
| 399 |
-
if not user.can_invite_users and user.status != CMS.OWNER:
|
| 400 |
await m.reply_text(text="You don't have rights to invite users....")
|
| 401 |
return False
|
| 402 |
|
|
@@ -427,7 +427,7 @@ async def get_invitelink(c: Gojo, m: Message):
|
|
| 427 |
async def setgtitle(_, m: Message):
|
| 428 |
user = await m.chat.get_member(m.from_user.id)
|
| 429 |
|
| 430 |
-
if not user.can_change_info and user.status != CMS.OWNER:
|
| 431 |
await m.reply_text(
|
| 432 |
"You don't have enough permission to use this command!",
|
| 433 |
)
|
|
@@ -450,7 +450,7 @@ async def setgtitle(_, m: Message):
|
|
| 450 |
async def setgdes(_, m: Message):
|
| 451 |
|
| 452 |
user = await m.chat.get_member(m.from_user.id)
|
| 453 |
-
if not user.can_change_info and user.status != CMS.OWNER:
|
| 454 |
await m.reply_text(
|
| 455 |
"You don't have enough permission to use this command!",
|
| 456 |
)
|
|
@@ -473,7 +473,7 @@ async def setgdes(_, m: Message):
|
|
| 473 |
async def set_user_title(c: Gojo, m: Message):
|
| 474 |
|
| 475 |
user = await m.chat.get_member(m.from_user.id)
|
| 476 |
-
if not user.can_promote_members and user.status != CMS.OWNER:
|
| 477 |
await m.reply_text(
|
| 478 |
"You don't have enough permission to use this command!",
|
| 479 |
)
|
|
@@ -516,7 +516,7 @@ async def set_user_title(c: Gojo, m: Message):
|
|
| 516 |
@Gojo.on_message(command("setgpic") & admin_filter)
|
| 517 |
async def setgpic(c: Gojo, m: Message):
|
| 518 |
user = await m.chat.get_member(m.from_user.id)
|
| 519 |
-
if not user.can_change_info and user.status != CMS.OWNER:
|
| 520 |
await m.reply_text(
|
| 521 |
"You don't have enough permission to use this command!",
|
| 522 |
)
|
|
|
|
| 183 |
await m.reply_text("Huh, how can I even promote myself?")
|
| 184 |
return
|
| 185 |
|
| 186 |
+
if not bot.privileges.can_promote_members:
|
| 187 |
return await m.reply_text(
|
| 188 |
"I don't have enough permissions!",
|
| 189 |
) # This should be here
|
|
|
|
| 300 |
await m.reply_text("Huh, how can I even promote myself?")
|
| 301 |
return
|
| 302 |
|
| 303 |
+
if not bot.privileges.can_promote_members:
|
| 304 |
return await m.reply_text(
|
| 305 |
"I don't have enough permissions",
|
| 306 |
) # This should be here
|
|
|
|
| 396 |
if m.from_user.id not in DEV_LEVEL:
|
| 397 |
user = await m.chat.get_member(m.from_user.id)
|
| 398 |
|
| 399 |
+
if not user.privileges.can_invite_users and user.status != CMS.OWNER:
|
| 400 |
await m.reply_text(text="You don't have rights to invite users....")
|
| 401 |
return False
|
| 402 |
|
|
|
|
| 427 |
async def setgtitle(_, m: Message):
|
| 428 |
user = await m.chat.get_member(m.from_user.id)
|
| 429 |
|
| 430 |
+
if not user.privileges.can_change_info and user.status != CMS.OWNER:
|
| 431 |
await m.reply_text(
|
| 432 |
"You don't have enough permission to use this command!",
|
| 433 |
)
|
|
|
|
| 450 |
async def setgdes(_, m: Message):
|
| 451 |
|
| 452 |
user = await m.chat.get_member(m.from_user.id)
|
| 453 |
+
if not user.privileges.can_change_info and user.status != CMS.OWNER:
|
| 454 |
await m.reply_text(
|
| 455 |
"You don't have enough permission to use this command!",
|
| 456 |
)
|
|
|
|
| 473 |
async def set_user_title(c: Gojo, m: Message):
|
| 474 |
|
| 475 |
user = await m.chat.get_member(m.from_user.id)
|
| 476 |
+
if not user.privileges.can_promote_members and user.status != CMS.OWNER:
|
| 477 |
await m.reply_text(
|
| 478 |
"You don't have enough permission to use this command!",
|
| 479 |
)
|
|
|
|
| 516 |
@Gojo.on_message(command("setgpic") & admin_filter)
|
| 517 |
async def setgpic(c: Gojo, m: Message):
|
| 518 |
user = await m.chat.get_member(m.from_user.id)
|
| 519 |
+
if not user.privileges.can_change_info and user.status != CMS.OWNER:
|
| 520 |
await m.reply_text(
|
| 521 |
"You don't have enough permission to use this command!",
|
| 522 |
)
|