Code: refresh code

This commit is contained in:
yaling888
2021-07-01 22:49:29 +08:00
parent 3ca5d17c40
commit d7732f6ebc
104 changed files with 11329 additions and 136 deletions

View File

@@ -2,6 +2,8 @@ package rules
import (
"errors"
C "github.com/Dreamacro/clash/constant"
)
var (
@@ -18,3 +20,14 @@ func HasNoResolve(params []string) bool {
}
return false
}
func findNetwork(params []string) C.NetWork {
for _, p := range params {
if p == "tcp" {
return C.TCP
} else if p == "udp" {
return C.UDP
}
}
return C.ALLNet
}