@@ -344,11 +344,7 @@ interface IPSHostProcessInfo {
344
344
}
345
345
346
346
export const GetPSHostProcessesRequestType =
347
- new RequestType < any , IGetPSHostProcessesResponseBody , string > ( "powerShell/getPSHostProcesses" ) ;
348
-
349
- interface IGetPSHostProcessesResponseBody {
350
- hostProcesses : IPSHostProcessInfo [ ] ;
351
- }
347
+ new RequestType < any , IPSHostProcessInfo [ ] , string > ( "powerShell/getPSHostProcesses" ) ;
352
348
353
349
export class PickPSHostProcessFeature extends LanguageClientConsumer {
354
350
@@ -427,17 +423,17 @@ export class PickPSHostProcessFeature extends LanguageClientConsumer {
427
423
} ] ;
428
424
429
425
const response = await this . languageClient ?. sendRequest ( GetPSHostProcessesRequestType , { } ) ;
430
- for ( const process of response ?. hostProcesses ?? [ ] ) {
431
- let windowTitle = "" ;
432
- if ( process . mainWindowTitle ) {
433
- windowTitle = `, Title: ${ process . mainWindowTitle } ` ;
434
- }
435
-
436
- items . push ( {
437
- label : process . processName ,
438
- description : `PID: ${ process . processId . toString ( ) } ${ windowTitle } ` ,
439
- pid : process . processId ,
440
- } ) ;
426
+ for ( const process of response ?? [ ] ) {
427
+ let windowTitle = "" ;
428
+ if ( process . mainWindowTitle ) {
429
+ windowTitle = `, Title: ${ process . mainWindowTitle } ` ;
430
+ }
431
+
432
+ items . push ( {
433
+ label : process . processName ,
434
+ description : `PID: ${ process . processId . toString ( ) } ${ windowTitle } ` ,
435
+ pid : process . processId ,
436
+ } ) ;
441
437
}
442
438
443
439
if ( items . length === 0 ) {
0 commit comments