Skip to content
Discussion options

You must be logged in to vote

Applies to: any version — this is how the project works by design.

An administrator can grant only roles below their own: «Наблюдатель» and «Редактор». Only the class's owner can make someone «Администратор».

  • The rule is can_grant in server/app/services/roles.py: a granted role must be strictly lower than the granter's. The server checks every grant with that one function, from the bot and from the app alike. Both pickers offer only what it allows, so you never see «Администратор». The server answers a forged button press with «Нельзя выдать роль выше вашей».
  • For the same reason you cannot change or remove another administrator or the owner. The bot answers «Нельзя менять роль этого поль…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by lumenpearson
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
area:bot for:admin Whoever keeps a class in the bot: members, the timetable, bells, homework, the school year
1 participant