Skip to content

Commit

Permalink
feat: roleの削除をサポート
Browse files Browse the repository at this point in the history
  • Loading branch information
yupix committed Mar 11, 2023
1 parent e934113 commit 5d0d438
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions mipac/actions/admins/roles.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,14 @@ async def create(
return Role(res)
raise NotSupportVersion(NotSupportVersionText)

async def delete(self, role_id: str) -> bool:
if self.__client._config.use_version >= 13:
res: bool = await self.__session.request(
Route('POST', '/api/admin/roles/delete'),
auth=True, json={'roleId': role_id}, lower=True
)
return res
raise NotSupportVersion(NotSupportVersionText)

async def show(self, role_id: str) -> Role:
if self.__client._config.use_version >= 13:
Expand Down

0 comments on commit 5d0d438

Please sign in to comment.