@@ -37,7 +37,6 @@ import {Controller} from './controller';
3737import { Debuggee } from '../debuggee' ;
3838import { StatusMessage } from '../client/stackdriver/status-message' ;
3939
40- // The following import syntax is used because './config' has a default export
4140import { defaultConfig } from './config' ;
4241import * as scanner from './io/scanner' ;
4342import * as SourceMapper from './io/sourcemapper' ;
@@ -283,10 +282,8 @@ export class Debuglet extends EventEmitter {
283282 const stat = promisify ( fs . stat ) ;
284283
285284 try {
286- // TODO: Address the fact that `that.config.workingDirectory` could
287- // be `null`.
288285 await stat (
289- path . join ( that . config . workingDirectory as string , 'package.json' ) ) ;
286+ path . join ( that . config . workingDirectory , 'package.json' ) ) ;
290287 } catch ( err ) {
291288 that . logger . error ( 'No package.json located in working directory.' ) ;
292289 that . emit ( 'initError' , new Error ( 'No package.json found.' ) ) ;
@@ -301,10 +298,8 @@ export class Debuglet extends EventEmitter {
301298
302299 let fileStats : scanner . ScanResults ;
303300 try {
304- // TODO: Address the case when `that.config.workingDirectory` is
305- // `null`.
306301 fileStats = await scanner . scan (
307- ! id , that . config . workingDirectory as string , / .j s $ | .m a p $ / ) ;
302+ ! id , that . config . workingDirectory , / .j s $ | .m a p $ / ) ;
308303 } catch ( err ) {
309304 that . logger . error ( 'Error scanning the filesystem.' , err ) ;
310305 that . emit ( 'initError' , err ) ;
0 commit comments