mirror of
https://gitclone.com/github.com/MetaCubeX/Clash.Meta
synced 2024-11-15 13:41:23 +08:00
19 lines
396 B
Go
19 lines
396 B
Go
// +build android,cmfa
|
|
|
|
package mmdb
|
|
|
|
import "github.com/oschwald/maxminddb-golang"
|
|
|
|
func InstallOverride(override *maxminddb.Reader) {
|
|
newReader := Reader{Reader: override}
|
|
switch override.Metadata.DatabaseType {
|
|
case "sing-geoip":
|
|
reader.databaseType = typeSing
|
|
case "Meta-geoip0":
|
|
reader.databaseType = typeMetaV0
|
|
default:
|
|
reader.databaseType = typeMaxmind
|
|
}
|
|
reader = newReader
|
|
}
|