diff --git a/main.go b/main.go index dab803d..e96da03 100644 --- a/main.go +++ b/main.go @@ -47,8 +47,8 @@ func (c *RTMPConfig) OnEvent(event any) { } } case InvitePublish: //按需拉流 - if url, ok := c.PullOnSub[v.Target]; ok { - pull(v.Target, url) + if remoteURL := conf.CheckPullOnSub(v.Target); remoteURL != "" { + pull(v.Target, remoteURL) } } }