Browse Source

Use o.Writer if not nil to write output (#330)

Use o.Writer if not nil to write output
Alexey Sudachén 7 years ago
parent
commit
7b40afb9bb
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      internal/driver/driver.go

+ 1
- 1
internal/driver/driver.go View File

138
 
138
 
139
 	// Output to specified file.
139
 	// Output to specified file.
140
 	o.UI.PrintErr("Generating report in ", output)
140
 	o.UI.PrintErr("Generating report in ", output)
141
-	out, err := os.Create(output)
141
+	out, err := o.Writer.Open(output)
142
 	if err != nil {
142
 	if err != nil {
143
 		return err
143
 		return err
144
 	}
144
 	}