优化虎牙

pull/51/head
肥羊 3 years ago committed by GitHub
parent 34ea18fdbd
commit f732236022
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 3
      Golang/liveurls/huya.go

@ -181,6 +181,9 @@ func (h *Huya) GetLiveUrl() any {
str := string(body)
freg := regexp.MustCompile(`"(?i)liveLineUrl":"([\s\S]*?)",`)
res := freg.FindStringSubmatch(str)
if h.Media == "hls" {
res = nil
}
if res == nil || res[1] == "" {
sreg := regexp.MustCompile(`(?i)<script> window.HNF_GLOBAL_INIT = (.*) </script>`)
nres := sreg.FindStringSubmatch(str)

Loading…
Cancel
Save