Skip to content

Commit

Permalink
Fixing some types
Browse files Browse the repository at this point in the history
  • Loading branch information
baronkobama authored and Lulalaby committed Jun 15, 2022
1 parent 404fca1 commit 137c147
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 8 deletions.
1 change: 1 addition & 0 deletions discord/types/audit_log.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@
110,
111,
112,
121,
]


Expand Down
3 changes: 2 additions & 1 deletion discord/types/channel.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,8 @@ class ThreadChannel(_BaseChannel, _ThreadChannelOptional):
]


class DMChannel(_BaseChannel):
class DMChannel(TypedDict):
id: Snowflake
type: Literal[1]
last_message_id: Optional[Snowflake]
recipients: List[PartialUser]
Expand Down
4 changes: 2 additions & 2 deletions discord/types/guild.py
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ class _GuildPreviewUnique(TypedDict):


class GuildPreview(_BaseGuildPreview, _GuildPreviewUnique):
...
pass


class Guild(_BaseGuildPreview, _GuildOptional):
Expand Down Expand Up @@ -163,7 +163,7 @@ class InviteGuild(Guild, total=False):


class GuildWithCounts(Guild, _GuildPreviewUnique):
...
pass


class GuildPrune(TypedDict):
Expand Down
4 changes: 2 additions & 2 deletions discord/types/invite.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,11 +65,11 @@ class IncompleteInvite(_InviteMetadata):


class Invite(IncompleteInvite, _InviteOptional):
...
pass


class InviteWithCounts(Invite, _GuildPreviewUnique):
...
pass


class _GatewayInviteCreateOptional(TypedDict, total=False):
Expand Down
4 changes: 2 additions & 2 deletions discord/types/member.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ class Nickname(TypedDict):
class PartialMember(TypedDict):
roles: SnowflakeList
joined_at: str
deaf: str
mute: str
deaf: bool
mute: bool


class Member(PartialMember, total=False):
Expand Down
2 changes: 1 addition & 1 deletion discord/types/webhook.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,4 +70,4 @@ class _FullWebhook(TypedDict, total=False):


class Webhook(PartialWebhook, _FullWebhook):
...
pass

0 comments on commit 137c147

Please sign in to comment.