producer connect throwing error

Hello, I have been following a few github projects to create my own client server mediasoup to stream sound.
I am having a problem where ‘produce’ is never called after ‘connect’ on the client. I am not sure what could be the problem since the error is very generic. I am not sure if this is the right place to be posting this.

Code flow go as follows:

Client → requests Capabilities_Params from server
Server → creates WebRtcTransport and Sends Capabilities_Params to client
Client → createSendTransport(params)
Client → get sound stream track and create producerparams
Client → create producerTransport.produce(producerparams)
Client → producerTransport ‘connect’ is called, send socketio packet to server passing dtlsparams from ‘onconnect’
Server → receives packet and calls connect(dtlsparams) for the WebRtcTransport object
Client → 'produce is never triggered

Why is ‘produce’ never triggered

You probably don’t call the callback in connect event handler. Docs have good examples of how to do it properly.

Ahhh Yes that was the case. Thank You