Skip to content

Commit

Permalink
image.go:Modify the ref validation
Browse files Browse the repository at this point in the history
Signed-off-by: zhouhao <zhouhao@cn.fujitsu.com>
  • Loading branch information
zhouhao committed Nov 28, 2016
1 parent b082914 commit 72a68e8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions image/image.go
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ func unpack(w walker, dest, refName string) error {
return err
}

if err = ref.validate(w, validRefMediaTypes); err != nil {
if err = ref.validate(w, []string{v1.MediaTypeImageManifest}); err != nil {
return err
}

Expand Down Expand Up @@ -162,7 +162,7 @@ func createRuntimeBundle(w walker, dest, refName, rootfs string) error {
return err
}

if err = ref.validate(w, validRefMediaTypes); err != nil {
if err = ref.validate(w, []string{v1.MediaTypeImageManifest}); err != nil {
return err
}

Expand Down

0 comments on commit 72a68e8

Please sign in to comment.