mirror of
https://github.com/shtorm-7/sing-box-extended.git
synced 2026-05-14 00:51:12 +03:00
Fix geo resource download path
This commit is contained in:
@@ -898,10 +898,9 @@ func (r *Router) prepareGeoIPDatabase() error {
|
||||
geoPath = "geoip.db"
|
||||
if foundPath, loaded := C.FindPath(geoPath); loaded {
|
||||
geoPath = foundPath
|
||||
} else {
|
||||
geoPath = C.BasePath(geoPath)
|
||||
}
|
||||
}
|
||||
geoPath = C.BasePath(geoPath)
|
||||
if !rw.FileExists(geoPath) {
|
||||
r.logger.Warn("geoip database not exists: ", geoPath)
|
||||
var err error
|
||||
@@ -935,10 +934,9 @@ func (r *Router) prepareGeositeDatabase() error {
|
||||
geoPath = "geosite.db"
|
||||
if foundPath, loaded := C.FindPath(geoPath); loaded {
|
||||
geoPath = foundPath
|
||||
} else {
|
||||
geoPath = C.BasePath(geoPath)
|
||||
}
|
||||
}
|
||||
geoPath = C.BasePath(geoPath)
|
||||
if !rw.FileExists(geoPath) {
|
||||
r.logger.Warn("geosite database not exists: ", geoPath)
|
||||
var err error
|
||||
|
||||
Reference in New Issue
Block a user