Skip to content
This repository has been archived by the owner on Nov 18, 2021. It is now read-only.

Commit

Permalink
cmd/cue: fix deduplication of message in vet
Browse files Browse the repository at this point in the history
Change-Id: I35dba3f0f9bf8479678d869470330a400e5a2b8f
Reviewed-on: https://cue-review.googlesource.com/c/cue/+/2377
Reviewed-by: Marcel van Lohuizen <mpvl@golang.org>
  • Loading branch information
mpvl committed Jul 1, 2019
1 parent 1700232 commit 4fcba03
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cmd/cue/cmd/vet.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,8 @@ func doVet(cmd *cobra.Command, args []string) error {
exprs = append(exprs, expr)
}

shown := false

for _, inst := range instances {
// TODO: use ImportPath or some other sanitized path.

Expand All @@ -64,7 +66,6 @@ func doVet(cmd *cobra.Command, args []string) error {
cue.Hidden(true),
}
w := cmd.OutOrStderr()
shown := false
err := inst.Value().Validate(append(opt, cue.Concrete(concrete))...)
if err != nil && !hasFlag {
err = inst.Value().Validate(append(opt, cue.Concrete(false))...)
Expand Down

0 comments on commit 4fcba03

Please sign in to comment.