Skip to content

Commit

Permalink
removes check on the artifact type filter
Browse files Browse the repository at this point in the history
Signed-off-by: Shiwei Zhang <[email protected]>
  • Loading branch information
shizhMSFT committed Apr 1, 2021
1 parent db537ea commit 60b9dab
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions cmd/oras/discover.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package main
import (
"context"
"encoding/json"
"errors"
"fmt"
"os"

Expand Down Expand Up @@ -44,12 +43,6 @@ Example - Discover artifacts of type "" linked with the specified reference:
oras discover --artifact-type application/vnd.cncf.notary.v2 localhost:5000/hello:latest
`,
Args: cobra.ExactArgs(1),
PreRunE: func(cmd *cobra.Command, args []string) error {
if opts.artifactType == "" {
return errors.New("artifact type not specified")
}
return nil
},
RunE: func(cmd *cobra.Command, args []string) error {
opts.targetRef = args[0]
return runDiscover(opts)
Expand Down

0 comments on commit 60b9dab

Please sign in to comment.