瀏覽代碼

no leaks no report

zricethezav 8 年之前
父節點
當前提交
095279d60c
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      leaks.go

+ 1 - 1
leaks.go

@@ -97,7 +97,7 @@ func start(repos []RepoDesc, owner *Owner, opts *Options) {
 			fmt.Printf("No Leaks detected for \x1b[35;2m%s\x1b[0m...\n\n", repo.url)
 		}
 
-		if opts.EnableJSON {
+		if opts.EnableJSON && len(report) != 0 {
 			outputGitLeaksReport(report, repo, opts)
 		}
 	}