Do not return nil on empty feature when json output is used.
This commit is contained in:
parent
8063fc9b2d
commit
1b75b9d454
@ -281,7 +281,7 @@ func AnalyzeLocalImage(imageName string, minSeverity types.Priority, endpoint, m
|
||||
fmt.Printf("Clair report for image %s (%s)\n", imageName, time.Now().UTC())
|
||||
}
|
||||
|
||||
if len(layer.Features) == 0 {
|
||||
if len(layer.Features) == 0 && !jsonOutput {
|
||||
fmt.Printf("%s No features have been detected in the image. This usually means that the image isn't supported by Clair.\n", color.YellowString("NOTE:"))
|
||||
return nil
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user