update to go1.26
This commit is contained in:
1 parent
5a35bf44fb
commit
b8b244acce
3 files changed
+22
-22
No files matched your search
@@ -9,7 +9,7 @@ jobs:
|
||||
docker:
|
||||
runs-on: ubuntu-latest
|
||||
container:
|
||||
image: catthehacker/ubuntu:act-latest
|
||||
image: ghcr.io/catthehacker/ubuntu:act-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v3
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
module iplookup
|
||||
|
||||
go 1.23.0
|
||||
go 1.26.0
|
||||
|
||||
require (
|
||||
github.com/oschwald/geoip2-golang v1.11.0
|
||||
|
||||
+20
-20
@@ -87,25 +87,25 @@ type Asn struct {
|
||||
}
|
||||
|
||||
type Info struct {
|
||||
Ip string
|
||||
Hostname string
|
||||
Query bool
|
||||
Port string
|
||||
UserAgent string
|
||||
MimeType string
|
||||
Language string
|
||||
ContentType string
|
||||
Encoding string
|
||||
Method string
|
||||
CacheControl string
|
||||
Referer string
|
||||
XForwardedFor string
|
||||
XForwardedProto string
|
||||
Cached bool
|
||||
Ttl int
|
||||
Geo Geo
|
||||
Asn Asn
|
||||
Ssl Ssl
|
||||
Ip string
|
||||
Hostname string
|
||||
Query bool
|
||||
Port string
|
||||
UserAgent string
|
||||
MimeType string
|
||||
Language string
|
||||
ContentType string
|
||||
Encoding string
|
||||
Method string
|
||||
CacheControl string
|
||||
Referer string
|
||||
XForwardedFor string
|
||||
XForwardedProto string
|
||||
Cached bool
|
||||
Ttl int
|
||||
Geo Geo
|
||||
Asn Asn
|
||||
Ssl Ssl
|
||||
}
|
||||
|
||||
type CacheEntry struct {
|
||||
@@ -560,7 +560,7 @@ func handler(w http.ResponseWriter, r *http.Request) {
|
||||
return
|
||||
}
|
||||
|
||||
for i := 0; i < len(cli); i++ {
|
||||
for i := range cli {
|
||||
if strings.Contains(r.UserAgent(), cli[i]) {
|
||||
isCli = true
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user