Skip to content

Commit fd55650

Browse files
committed
fix: linter error (#246)
Fix linter error <!-- greptile_comment --> ## Greptile Summary Updates variable naming in `common/docker/client_image.go` to fix linter errors by renaming duplicate 'ok' variables in type assertions within the parseNonBuildkitResp function. - Improved code clarity by using distinct variable names (ok2, ok3) instead of reusing 'ok' for multiple type assertions in error handling flow - Change maintains existing functionality while addressing linter warnings for Docker build output processing <!-- /greptile_comment -->
1 parent 686604b commit fd55650

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

common/docker/client_image.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -440,8 +440,8 @@ func (c *Client) parseNonBuildkitResp(decoder *json.Decoder, stop *bool) (string
440440

441441
// Check for error details
442442
if errorDetail, ok := event["errorDetail"]; ok {
443-
if errorDetailMap, ok := errorDetail.(map[string]interface{}); ok { //nolint:govet
444-
if message, ok := errorDetailMap["message"]; ok && message != "" { //nolint:govet
443+
if errorDetailMap, ok2 := errorDetail.(map[string]interface{}); ok2 {
444+
if message, ok3 := errorDetailMap["message"]; ok3 && message != "" {
445445
return "", eris.New(message.(string))
446446
}
447447
}

0 commit comments

Comments
 (0)