@@ -9,15 +9,16 @@ class Flake8Process {
99 async process ( commandArguments ) {
1010 let flake8Path = nova . workspace . config . get ( "is.flother.Blake.flake8ExecutablePath" ) ;
1111 const maxLineLength = nova . workspace . config . get ( "is.flother.Blake.maxLineLength" ) ;
12+ let args = commandArguments ;
1213 if ( maxLineLength ) {
13- commandArguments = [ "--max-line-length" , maxLineLength . toString ( ) , ...commandArguments ] ;
14+ args = [ "--max-line-length" , maxLineLength . toString ( ) , ...args ] ;
1415 }
1516 if ( ! flake8Path ) {
1617 flake8Path = "/usr/bin/env" ;
17- commandArguments = [ "flake8" , ...commandArguments ] ;
18+ args = [ "flake8" , ...args ] ;
1819 }
1920 return new Process ( flake8Path , {
20- args : commandArguments ,
21+ args,
2122 cwd : nova . workspace . path ,
2223 shell : true ,
2324 stdio : [ "ignore" , "pipe" , "pipe" ] ,
@@ -56,17 +57,18 @@ class Flake8Process {
5657 request . actions = [ nova . localize ( "OK" ) ] ;
5758 const promise = nova . notifications . add ( request ) ;
5859 promise . then (
59- _ => { } ,
60+ ( ) => { } ,
6061 error => {
62+ // eslint-disable-next-line no-console -- Last ditch attempt to put the error somewhere.
6163 console . error ( error ) ;
6264 }
6365 ) ;
6466 }
65- this . _onCompleteCallback ( this . violations ) ;
67+ this . onCompleteCallback ( this . violations ) ;
6668 }
6769
6870 onComplete ( callback ) {
69- this . _onCompleteCallback = callback ;
71+ this . onCompleteCallback = callback ;
7072 }
7173}
7274
0 commit comments