Skip to content
This repository has been archived by the owner on Dec 26, 2022. It is now read-only.

Commit

Permalink
📝 Docs improvements (#434)
Browse files Browse the repository at this point in the history
  • Loading branch information
kylianpl authored Feb 20, 2022
1 parent 35cc1f8 commit 7b00f52
Showing 1 changed file with 14 additions and 4 deletions.
18 changes: 14 additions & 4 deletions pincer/objects/guild/channel.py
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ async def edit(self, reason: Optional[str] = None, **kwargs):
Parameters
----------
reason Optional[:class:`str`]
The reason of the channel delete.
The reason of the channel edit.
\\*\\*kwargs :
The keyword arguments to edit the channel with.
Expand Down Expand Up @@ -289,7 +289,7 @@ async def edit_permissions(
type: :class:`int`
0 for a role or 1 for a member.
reason: Optional[:class:`str`]
The reason of the channel delete.
The reason of the channel permission edit.
"""
await self._http.put(
f"channels/{self.id}/permissions/{overwrite.id}",
Expand All @@ -309,7 +309,7 @@ async def delete_permission(
overwrite: :class:`~pincer.objects.guild.overwrite.Overwrite`
The overwrite object.
reason: Optional[:class:`str`]
The reason of the channel delete.
The reason of the channel permission delete.
"""
await self._http.delete(
f"channels/{self.id}/permissions/{overwrite.id}",
Expand Down Expand Up @@ -372,6 +372,11 @@ async def pin_message(
"""|coro|
Pin a message in a channel. Requires the ``MANAGE_MESSAGES`` permission.
The maximum number of pinned messages is ``50``.
Parameters
----------
reason: Optional[:class:`str`]
The reason of the channel message pin.
"""
await self._http.put(
f"channels/{self.id}/pins/{message.id}",
Expand All @@ -383,6 +388,11 @@ async def unpin_message(
):
"""|coro|
Unpin a message in a channel. Requires the ``MANAGE_MESSAGES`` permission.
Parameters
----------
reason: Optional[:class:`str`]
The reason of the channel message unpin.
"""
await self._http.delete(
f"channels/{self.id}/pins/{message.id}",
Expand Down Expand Up @@ -441,7 +451,7 @@ async def bulk_delete_messages(
messages: List[:class:`~.pincer.utils.Snowflake`]
The list of message IDs to delete (2-100).
reason: Optional[:class:`str`]
The reason of the channel delete.
The reason of the channel bulk delete.
"""
await self._http.post(
f"channels/{self.id}/messages/bulk_delete",
Expand Down

0 comments on commit 7b00f52

Please sign in to comment.