Fix WebRTC card stuck in loading #1417

This commit is contained in:
Alex X
2024-10-29 14:39:37 +03:00
parent 780f378fb1
commit 3f94a754e4
+7 -1
View File
@@ -100,6 +100,10 @@ func Patch(name string, source string) *Stream {
return nil
}
if Validate(source) != nil {
return nil
}
// check an existing stream with this name
if stream, ok := streams[name]; ok {
stream.SetSource(source)
@@ -107,7 +111,9 @@ func Patch(name string, source string) *Stream {
}
// create new stream with this name
return New(name, source)
stream := NewStream(source)
streams[name] = stream
return stream
}
func GetOrPatch(query url.Values) *Stream {