Refactor: script auto load geosite as a rule provider

This commit is contained in:
yaling888
2022-06-06 04:28:54 +08:00
parent e03f1d0565
commit 05f0c1060b
4 changed files with 49 additions and 16 deletions

View File

@@ -55,6 +55,9 @@ func NewGEOSITE(country string, adapter string) (*GEOSITE, error) {
if recordsCount == 0 {
cont = "from cache"
}
if adapter == C.ScriptRuleGeoSiteTarget {
adapter = "Script"
}
log.Infoln("Start initial GeoSite rule %s => %s, records: %s", country, adapter, cont)
geoSite := &GEOSITE{