Skip to content

Updated websocket to be current#773

Merged
Psychoboy merged 2 commits intomainfrom
updateWebSockets
Feb 25, 2026
Merged

Updated websocket to be current#773
Psychoboy merged 2 commits intomainfrom
updateWebSockets

Conversation

@Psychoboy
Copy link
Copy Markdown
Owner

No description provided.

Copilot AI review requested due to automatic review settings February 25, 2026 17:14
Copy link
Copy Markdown
Contributor

Copilot AI left a 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 updates the TwitchLib.EventSub libraries to current versions and refactors the codebase to use the new API structure where event data is accessed through Payload and Metadata properties directly rather than through a Notification wrapper.

Changes:

  • Updated TwitchLib.EventSub.Websockets and TwitchLib.EventSub.Core submodule commits
  • Migrated namespace imports from TwitchLib.EventSub.Websockets.Core.EventArgs to TwitchLib.EventSub.Core.EventArgs
  • Refactored all event handlers to access event data via args.Payload.Event and args.Metadata instead of args.Notification.Payload.Event and args.Notification.Metadata

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
TwitchLib.EventSub.Websockets Updated submodule to newer commit
TwitchLib.EventSub.Core Updated submodule to newer commit
TwitchWebsocketHostedService.cs Updated event handlers to use new API structure and added type safety checks
IChatHistory.cs Updated namespace import
ChatHistory.cs Updated namespace import and event data access pattern
DeletedChatMessage.cs Updated namespace import
DeleteChatMessage.cs Added blank line
DotNetTwitchBot.sln Added TwitchLib.EventSub.Core project and removed extraneous text from version string

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

return false;
}
var metadata = eventSubMetaData as WebsocketEventSubMetadata;
if(metadata == null)
Copy link

Copilot AI Feb 25, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing space after if keyword. C# style guidelines recommend a space between control flow keywords and their opening parenthesis.

Suggested change
if(metadata == null)
if (metadata == null)

Copilot uses AI. Check for mistakes.
{
public Task Handle(DeletedChatMessage notification, CancellationToken cancellationToken)
{

Copy link

Copilot AI Feb 25, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unnecessary blank line added. This adds no value and should be removed to maintain consistency with the rest of the codebase.

Suggested change

Copilot uses AI. Check for mistakes.
…e.cs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@Psychoboy Psychoboy merged commit d681d16 into main Feb 25, 2026
5 of 6 checks passed
@Psychoboy Psychoboy deleted the updateWebSockets branch February 25, 2026 17:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants