From 3106b2820bc88f66ce8d83ae45de18f21862022a Mon Sep 17 00:00:00 2001 From: Vaughn Dice Date: Tue, 13 Aug 2019 11:32:10 -0600 Subject: [PATCH] fix(bundle.go): add omitempty to contentDigest yaml tag --- bundle/bundle.go | 2 +- testdata/bundles/bundle.yaml | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/bundle/bundle.go b/bundle/bundle.go index 3c2568a7..efcf7bbc 100644 --- a/bundle/bundle.go +++ b/bundle/bundle.go @@ -81,7 +81,7 @@ type LocationRef struct { type BaseImage struct { ImageType string `json:"imageType" yaml:"imageType"` Image string `json:"image" yaml:"image"` - Digest string `json:"contentDigest,omitempty" yaml:"contentDigest"` + Digest string `json:"contentDigest,omitempty" yaml:"contentDigest,omitempty"` Size uint64 `json:"size,omitempty" yaml:"size,omitempty"` Labels map[string]string `json:"labels,omitempty" yaml:"labels,omitempty"` MediaType string `json:"mediaType,omitempty" yaml:"mediaType,omitempty"` diff --git a/testdata/bundles/bundle.yaml b/testdata/bundles/bundle.yaml index 6567210e..91c88908 100644 --- a/testdata/bundles/bundle.yaml +++ b/testdata/bundles/bundle.yaml @@ -5,14 +5,12 @@ description: something invocationImages: - imageType: docker image: deislabs/invocation-image:1.0 - contentDigest: "" labels: os: Linux images: server: imageType: docker image: nginx:1.0 - contentDigest: "" description: complicated parameters: enabled: