Skip to content

Commit 3703581

Browse files
committed
task: rename file to match go style
1 parent faffbe3 commit 3703581

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

requiredRole.go renamed to required_role.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@ import (
2121
)
2222

2323
func requiredRole(buf *bytes.Buffer, cmd *cobra.Command) {
24-
if cmd.Annotations["requiredRole"] != "" {
25-
buf.WriteString("\nTo use this command, the requesting user or API key must have the " + cmd.Annotations["requiredRole"] + " role.\n")
24+
if cmd.Annotations["requiredRole"] == "" {
25+
return
2626
}
27+
buf.WriteString("\nTo use this command, the requesting user or API key must have the " + cmd.Annotations["requiredRole"] + " role.\n")
2728
}

0 commit comments

Comments
 (0)