-
-
Notifications
You must be signed in to change notification settings - Fork 41
fix: potential fix for member parsing causing ac to silently fail #750
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
Conversation
24829eb to
dbe9efc
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR fixes a bug in application command (AC) member parsing that was causing commands to fail silently. The issue occurred when resolved members in interactions didn't have their ManualUser property initialized, leading to null reference exceptions when accessing member user data.
Key Changes:
- Fixed member parsing in interaction resolution by ensuring
ManualUseris properly initialized before accessing member user properties - Added
GuildDisplayNameStylesproperty to support guild-specific display name styling - Corrected JSON serialization by adding
JsonIgnoreto the overriddenDisplayNameStylesproperty to prevent conflicts
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| DisCatSharp/Entities/Guild/DiscordMember.cs | Added GuildDisplayNameStyles property, corrected documentation comments for guild-specific properties, and added JsonIgnore to DisplayNameStyles override |
| DisCatSharp/Clients/DiscordClient.Dispatch.cs | Fixed member parsing bug by initializing ManualUser property before accessing User property in resolved members, simplified null-conditional access for PartialGuild |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
No description provided.