Open Thowaah opened 3 years ago
I was facing a similar issue until I did the following
websocketServer.AddWebSocketService<Chat>("/ChatWithNyan", p => new Chat(" Nyan!"));
Although this fixed the error, I can't get the params to be passed to the Service
When trying to build this simple example from the README
I get this error on the lambda:
Delegate 'Action<Chat>' does not take 0 arguments
It does the same if I take Example2 and uncomment those lines:
wssv.AddWebSocketService<Chat>("/Chat", () =>new Chat("Anon#") {...}
If I do not use the initialization with the lambda, the example runs fine (see below).
I will need the initialization to pass some data to my WebsocketService. Do someone have any idea of what could be going wrong ? Thanks.