mirror of
https://github.com/coder/coder.git
synced 2026-06-02 20:48:20 +00:00
chore: remove unnecessary loop variable captures (#22180)
Since Go 1.22, the loop variable capture issue is resolved. Variables declared by for loops are now per-iteration rather than per-loop, making the 'v := v' pattern unnecessary.
This commit is contained in:
@@ -297,7 +297,6 @@ func holdConnection(ctx context.Context, logs io.Writer, conn workspacesdk.Agent
|
||||
_, _ = fmt.Fprintln(logs, "\nStarting connection loops...")
|
||||
}
|
||||
for i, connSpec := range specs {
|
||||
i, connSpec := i, connSpec
|
||||
if connSpec.Interval <= 0 {
|
||||
continue
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user