Add auto create new stream for async webrtc

This commit is contained in:
Alexey Khit
2022-12-25 11:17:14 +03:00
parent 654fa32b3a
commit 9739f7f416

View File

@@ -68,7 +68,7 @@ var NewPConn func() (*pion.PeerConnection, error)
func asyncHandler(tr *api.Transport, msg *api.Message) error {
src := tr.Request.URL.Query().Get("src")
stream := streams.Get(src)
stream := streams.GetOrNew(src)
if stream == nil {
return errors.New(api.StreamNotFound)
}