Skip to content

Commit

Permalink
Don't print 'Ignoring cache image "cache-image-name" because it was c…
Browse files Browse the repository at this point in the history
…orrupt' (buildpacks#1185)

when the cache image is not found

Signed-off-by: Natalie Arellano <narellano@vmware.com>
  • Loading branch information
natalieparellano committed Sep 12, 2023
1 parent afd41e2 commit 291a466
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cache/image_cache.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ func (c *ImageCache) SetMetadata(metadata platform.CacheMetadata) error {
}

func (c *ImageCache) RetrieveMetadata() (platform.CacheMetadata, error) {
if !c.origImage.Valid() {
if c.origImage.Found() && !c.origImage.Valid() {
c.logger.Infof("Ignoring cache image %q because it was corrupt", c.origImage.Name())
return platform.CacheMetadata{}, nil
}
Expand Down

0 comments on commit 291a466

Please sign in to comment.