File tree Expand file tree Collapse file tree 1 file changed +10
-8
lines changed Expand file tree Collapse file tree 1 file changed +10
-8
lines changed Original file line number Diff line number Diff line change @@ -25,14 +25,16 @@ export async function main(): Promise<void> {
2525
2626 const output = cli . getOutput ( diff2htmlOptions , configuration , input ) ;
2727
28- if ( configuration . outputDestinationFile ) utils . writeFile ( configuration . outputDestinationFile , output ) ;
29-
30- switch ( configuration . outputDestinationType ) {
31- case 'preview' :
32- return cli . preview ( output , configuration . formatType ) ;
33-
34- case 'stdout' :
35- return log . print ( output ) ;
28+ if ( configuration . outputDestinationFile ) {
29+ utils . writeFile ( configuration . outputDestinationFile , output ) ;
30+ } else {
31+ switch ( configuration . outputDestinationType ) {
32+ case 'preview' :
33+ return cli . preview ( output , configuration . formatType ) ;
34+
35+ case 'stdout' :
36+ return log . print ( output ) ;
37+ }
3638 }
3739 } catch ( error ) {
3840 if ( process . exitCode === undefined || process . exitCode === 0 ) {
You can’t perform that action at this time.
0 commit comments