Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: correctly handle resolved member objects in interactions payload over http #364

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/interactions/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -540,7 +540,7 @@
client,
data,
resolved.users[id],
undefined as unknown as Guild
guild!

Check failure on line 543 in src/interactions/client.ts

View workflow job for this annotation

GitHub Actions / build

This assertion is unnecessary since it does not change the type of the expression
)
}

Expand All @@ -552,7 +552,7 @@
resolved.roles[id] = new Role(
client,
data,
undefined as unknown as Guild
guild!

Check failure on line 555 in src/interactions/client.ts

View workflow job for this annotation

GitHub Actions / build

This assertion is unnecessary since it does not change the type of the expression
)
}

Expand Down
2 changes: 1 addition & 1 deletion src/structures/member.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export class Member extends SnowflakeBase {
perms?: Permissions
) {
super(client)
this.id = data.user.id
this.id = user.id
this.readFromData(data)
this.user = user
this.guild = guild
Expand Down
Loading