Skip to content

Commit

Permalink
Merge pull request #296 from endophage/pretty_print_targets
Browse files Browse the repository at this point in the history
headers were still printing when no targets were found
  • Loading branch information
diogomonica committed Nov 15, 2015
2 parents ebc41c8 + d0b3bd2 commit 4f347a1
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cmd/notary/tuf.go
Original file line number Diff line number Diff line change
Expand Up @@ -461,7 +461,8 @@ func (t targetsSorter) Less(i, j int) bool {
// root keys and then the signing keys.
func prettyPrintTargets(ts []*notaryclient.Target, writer io.Writer) {
if len(ts) == 0 {
writer.Write([]byte("No targets present in this repository.\n"))
writer.Write([]byte("\nNo targets present in this repository.\n\n"))
return
}

sort.Stable(targetsSorter(ts))
Expand Down

0 comments on commit 4f347a1

Please sign in to comment.