Skip to content

Commit

Permalink
remove LOOP labels
Browse files Browse the repository at this point in the history
  • Loading branch information
jabdoa2 committed Jul 12, 2024
1 parent 67ec88c commit d604f40
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
3 changes: 1 addition & 2 deletions pkg/bundle/source.go
Original file line number Diff line number Diff line change
Expand Up @@ -371,11 +371,10 @@ func deduplicateAndSortBundles(bundles []string) ([]string, error) {
for _, cert := range bundles {
certBytes := []byte(cert)

LOOP:
for {
block, certBytes = pem.Decode(certBytes)
if block == nil {
break LOOP
break
}

if block.Type != "CERTIFICATE" {
Expand Down
7 changes: 3 additions & 4 deletions test/env/data.go
Original file line number Diff line number Diff line change
Expand Up @@ -217,11 +217,10 @@ func CheckBundleSyncedContains(ctx context.Context, cl client.Client, name strin
var block *pem.Block
certBytes := []byte(containedData)

LOOP:
for {
block, certBytes = pem.Decode(certBytes)
if block == nil {
break LOOP
break
}

if block.Type != "CERTIFICATE" {
Expand All @@ -236,11 +235,11 @@ func CheckBundleSyncedContains(ctx context.Context, cl client.Client, name strin
certBytes = []byte(got)
// check that there are a nonzero number of valid certs remaining
found := false
LOOP2:

for {
block, certBytes = pem.Decode(certBytes)
if block == nil {
break LOOP2
break
}

if block.Type != "CERTIFICATE" {
Expand Down

0 comments on commit d604f40

Please sign in to comment.