Fix panic on Producer GetMedias
This commit is contained in:
@@ -56,6 +56,10 @@ func (p *Producer) GetMedias() []*core.Media {
|
|||||||
p.mu.Lock()
|
p.mu.Lock()
|
||||||
defer p.mu.Unlock()
|
defer p.mu.Unlock()
|
||||||
|
|
||||||
|
if p.conn == nil {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
return p.conn.GetMedias()
|
return p.conn.GetMedias()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user