From c0c7577ab10aec619e74b8c1a9133cbc42c70ff1 Mon Sep 17 00:00:00 2001 From: langhuihui <178529795@qq.com> Date: Mon, 23 Oct 2023 14:15:30 +0800 Subject: [PATCH] feat: add regexp when pullonsub --- main.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) 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) } } }