Replace ErrNotFound constant with errors.New for consistent error handling

This commit is contained in:
2026-04-11 17:21:39 +05:00
parent f2657471c4
commit 9e0c065ecc
2 changed files with 3 additions and 3 deletions
+1 -2
View File
@@ -1,7 +1,6 @@
package mmdb
import (
"errors"
"net/netip"
"git.kor-elf.net/kor-elf-shield/geoip2"
@@ -47,7 +46,7 @@ func (c *City) infoCity(ip netip.Addr, reader *oschwaldGeoip2.Reader) (geoip2.In
return geoip2.Info{}, err
}
if !record.HasData() {
return geoip2.Info{}, errors.New(geoip2.ErrNotFound)
return geoip2.Info{}, geoip2.ErrNotFound
}
var timeZone string