11const Linter = require ( "./Linter" ) ;
22const Formatter = require ( "./Formatter" ) ;
33
4- exports . activate = function ( ) {
4+ exports . activate = function ( ) {
55 const linter = new Linter ( ) ;
66 const formatter = new Formatter ( ) ;
77
8- nova . workspace . onDidAddTextEditor ( ( editor ) => {
8+ nova . workspace . onDidAddTextEditor ( editor => {
99 const document = editor . document ;
1010
1111 if ( document . syntax !== "python" ) {
@@ -14,17 +14,17 @@ exports.activate = function () {
1414
1515 linter . lintDocument ( document ) ;
1616
17- editor . onDidSave ( ( editor ) => linter . lintDocument ( document ) ) ;
18- document . onDidChangeSyntax ( ( document ) => linter . lintDocument ( document ) ) ;
19- editor . onWillSave ( ( editor ) => {
17+ editor . onDidSave ( editor => linter . lintDocument ( document ) ) ;
18+ document . onDidChangeSyntax ( document => linter . lintDocument ( document ) ) ;
19+ editor . onWillSave ( editor => {
2020 const formatOnSave = nova . workspace . config . get ( "is.flother.Blake.formatOnSave" ) ;
2121 if ( formatOnSave ) {
2222 return formatter . format ( editor ) ;
2323 }
2424 } ) ;
2525
26- editor . onDidDestroy ( ( destroyedEditor ) => {
27- const anotherEditor = nova . workspace . textEditors . find ( ( editor ) => {
26+ editor . onDidDestroy ( destroyedEditor => {
27+ const anotherEditor = nova . workspace . textEditors . find ( editor => {
2828 return editor . document . path === destroyedEditor . document . path ;
2929 } ) ;
3030 if ( ! anotherEditor ) {
@@ -33,5 +33,5 @@ exports.activate = function () {
3333 } ) ;
3434 } ) ;
3535
36- nova . commands . register ( "formatSourceCodeWithBlack" , ( editor ) => formatter . format ( editor ) ) ;
36+ nova . commands . register ( "formatSourceCodeWithBlack" , editor => formatter . format ( editor ) ) ;
3737} ;
0 commit comments