Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork156
Open
Description
The problem I am facing
It's a bit confusing that there is aconnection
key in various hook payloads that is either aConnection
instance or aConnectionConfiguration
object. Both are quite different:
Connection
webSocket:WebSocket context:any document:Document pingInterval:NodeJS.TimeoutpongReceived=true request:HTTPIncomingMessage timeout:number callbacks:any socketId:string lock:AsyncLock readOnly:Boolean logger:Debugger
ConnectionConfiguration
readOnly:boolean requiresAuthentication:boolean isAuthenticated:boolean
But they appear to be the same at first glance:
onConnect({connection}){// connection is ConnectionConfiguration})beforeHandleMessage({connection}){// connection is Connection})
The solution I would like
It would be great ifConnectionConfiguration
were alwaysconnectionConfig
andConnection
were alwaysconnection
.