lint(revive): fix indent-error-flow violations (#7977)

This commit is contained in:
Ville Vesilehto
2026-03-30 03:01:22 +03:00
committed by GitHub
parent 7fd983b02c
commit 867cd8fd6b
4 changed files with 12 additions and 14 deletions

View File

@@ -175,20 +175,19 @@ func (z *Zone) nameFromRight(qname string, i int) (string, bool) {
n := len(qname)
for j := 1; j <= z.origLen; j++ {
if m, shot := dns.PrevLabel(qname[:n], 1); shot {
m, shot := dns.PrevLabel(qname[:n], 1)
if shot {
return qname, shot
} else {
n = m
}
n = m
}
for j := 1; j <= i; j++ {
m, shot := dns.PrevLabel(qname[:n], 1)
if shot {
return qname, shot
} else {
n = m
}
n = m
}
return qname[n:], false
}