SocketIOFacade: Add missing locking on .Off calls

This commit is contained in:
softworkz
2025-11-10 21:27:33 +01:00
parent 41a2b075c9
commit f89f2e7591

View File

@@ -86,7 +86,7 @@ internal class SocketIoFacade
{
_socket.On(eventName, _ =>
{
_socket.Off(eventName);
this.Off(eventName);
Task.Run(action);
});
}
@@ -98,7 +98,7 @@ internal class SocketIoFacade
{
_socket.On(eventName, (socketIoResponse) =>
{
_socket.Off(eventName);
this.Off(eventName);
Task.Run(() => action(socketIoResponse.GetValue<T>()));
});
}