Skip to content

Commit 3a21e1e

Browse files
committed
Fix Linting Issues
Signed-off-by: AhmedGrati <[email protected]>
1 parent b670aef commit 3a21e1e

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

cmd/formatter/colors.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,7 @@ func cleanInfiniteGoroutine() {
9999
}
100100

101101
func init() {
102+
defer cleanInfiniteGoroutine()
102103
colors := map[string]colorFunc{}
103104
for i, name := range names {
104105
colors[name] = makeColorFunc(strconv.Itoa(30 + i))
@@ -131,5 +132,4 @@ func init() {
131132
}
132133
}()
133134

134-
defer cleanInfiniteGoroutine()
135135
}

cmd/formatter/formatter_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,5 +75,5 @@ func TestPrint(t *testing.T) {
7575

7676
// Test the absence of unexpected goroutines.
7777
func TestColorsGoroutinesLeak(t *testing.T) {
78-
defer goleak.VerifyNone(t)
78+
goleak.VerifyNone(t)
7979
}

0 commit comments

Comments
 (0)