mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-09-02 16:37:14 +00:00
chore(build): bump Go toolchain to 1.27.0
Go 1.27.0 shipped on 2026-08-19. Raise the go directive and the builder image so Docker and release builds pick it up; every CI job already reads the version from go.mod, and golangci-lint v2.13.1 release binaries are themselves built with go1.27.0, so the lint job needs no pin change.
This commit is contained in:
@@ -2,6 +2,7 @@ package job
|
||||
|
||||
import (
|
||||
"net/netip"
|
||||
"slices"
|
||||
"strings"
|
||||
)
|
||||
|
||||
@@ -16,7 +17,7 @@ type ipLimitAllowlist struct {
|
||||
// skipped: the validator uses these same rules, so only a hand-edited DB differs.
|
||||
func parseIpLimitAllowlist(raw string) ipLimitAllowlist {
|
||||
var list ipLimitAllowlist
|
||||
for _, field := range strings.Split(raw, ",") {
|
||||
for field := range strings.SplitSeq(raw, ",") {
|
||||
field = strings.TrimSpace(field)
|
||||
if field == "" {
|
||||
continue
|
||||
@@ -52,10 +53,8 @@ func (l ipLimitAllowlist) contains(ip string) bool {
|
||||
return false
|
||||
}
|
||||
addr = addr.Unmap()
|
||||
for _, allowed := range l.addrs {
|
||||
if allowed == addr {
|
||||
return true
|
||||
}
|
||||
if slices.Contains(l.addrs, addr) {
|
||||
return true
|
||||
}
|
||||
for _, prefix := range l.prefixes {
|
||||
if prefix.Contains(addr) {
|
||||
|
||||
Reference in New Issue
Block a user