Skip to content

Commit 730c357

Browse files
committed
fix(linter): lint issues
1 parent 33a998a commit 730c357

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

internal/parameter/group.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,10 +79,10 @@ func (g *Group) Render(all map[FieldKey]huh.Field, fields []huh.Field) *huh.Grou
7979
return !orMet
8080
}
8181
if orCount < 1 && andCount > 0 {
82-
return !(andCount == andMetCount)
82+
return andCount != andMetCount
8383
}
8484
if orCount > 0 && andCount > 0 {
85-
return !(orMet && andMetCount == orCount)
85+
return !orMet || andMetCount != orCount
8686
}
8787
return false
8888
})

internal/parameter/secret/secret.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ func (p *Param) Validate() []error {
2525
}
2626

2727
func (p *Param) Render() {
28-
param := p.Param.RenderInput()
28+
param := p.RenderInput()
2929
param.EchoMode(huh.EchoModePassword)
3030

3131
// reset validators of the secret

internal/parameter/validators/str.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,9 +88,9 @@ func isIP(input string) int32 {
8888
}
8989

9090
func isIPv4(input string) bool {
91-
return 4 == isIP(input)
91+
return isIP(input) == 4
9292
}
9393

9494
func isIPv6(input string) bool {
95-
return 6 == isIP(input)
95+
return isIP(input) == 6
9696
}

0 commit comments

Comments
 (0)