Skip to content

Commit

Permalink
minor fixes in file output. it's working fine now
Browse files Browse the repository at this point in the history
  • Loading branch information
mosajjal committed Jan 16, 2021
1 parent e4dc933 commit 6c013b2
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,10 @@ func checkFlags() {
}
if *fileOutputType == "none" || *fileOutputType == "" {
fileOutputBool = false
} else {
if *fileOutputPath == "" {
log.Fatal("fileOutputType is set but fileOutputPath is not provided. Exiting")
}
}
if *clickhouseOutputType != "all" && *clickhouseOutputType != "skipdomains" && *clickhouseOutputType != "allowdomains" && *clickhouseOutputType != "none" && *clickhouseOutputType != "" {
log.Fatal("clickhouseOutputType must be one of all, skipdomains, allowdomains, none.")
Expand Down Expand Up @@ -266,7 +270,7 @@ func main() {
go dispatchOutput(resultChannel, exiting, &wg)

if fileOutputBool {
go fileOutput(stdoutResultChannel, exiting, &wg)
go fileOutput(fileResultChannel, exiting, &wg)
}
if stdoutOutputBool {
go stdoutOutput(stdoutResultChannel, exiting, &wg)
Expand Down

0 comments on commit 6c013b2

Please sign in to comment.