|coro| Destroys a player on the node. It's recommended that you use :func:`PlayerManager.destroy` to destroy a player. Returns ------- bool Whether the player was destroyed.
(self, guild_id: Union[str, int])
| 568 | params=params, json=json) # type: ignore |
| 569 | |
| 570 | async def destroy_player(self, guild_id: Union[str, int]) -> bool: |
| 571 | """|coro| |
| 572 | |
| 573 | Destroys a player on the node. |
| 574 | It's recommended that you use :func:`PlayerManager.destroy` to destroy a player. |
| 575 | |
| 576 | Returns |
| 577 | ------- |
| 578 | bool |
| 579 | Whether the player was destroyed. |
| 580 | """ |
| 581 | session_id = self.session_id |
| 582 | |
| 583 | if not session_id: |
| 584 | raise ClientError('Cannot destroy a player without a valid session ID!') |
| 585 | |
| 586 | return await self.request('DELETE', f'sessions/{session_id}/players/{guild_id}') # type: ignore |
| 587 | |
| 588 | async def update_session(self, resuming: bool = MISSING, timeout: int = MISSING) -> Optional[RawSession]: |
| 589 | """|coro| |
no test coverage detected