mirror of
https://github.com/MetaCubeX/mihomo.git
synced 2026-03-03 12:17:31 +00:00
fix: update mmdb fail
This commit is contained in:
@@ -57,7 +57,7 @@ func Verify() bool {
|
||||
func Instance() Reader {
|
||||
once.Do(func() {
|
||||
mmdbPath := C.Path.MMDB()
|
||||
log.Debugln("Load MMDB file: %s", mmdbPath)
|
||||
log.Infoln("Load MMDB file: %s", mmdbPath)
|
||||
mmdb, err := maxminddb.Open(mmdbPath)
|
||||
if err != nil {
|
||||
log.Fatalln("Can't load MMDB: %s", err.Error())
|
||||
@@ -94,3 +94,7 @@ func DownloadMMDB(path string) (err error) {
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
func Reload() {
|
||||
once = sync.Once{}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user