提交 3f6901d4 编写于 作者: A Andre Weinand

correct fix for #63028

上级 33c89529
......@@ -625,8 +625,6 @@ export class ExtHostDebugService implements ExtHostDebugServiceShape {
type: 'implementation',
implementation: x.implementation
};
} else if (typeof (<any>x).type === 'string') {
return <IAdapterDescriptor>x;
} else {
throw new Error('unexpected type');
}
......@@ -718,8 +716,7 @@ export class ExtHostDebugService implements ExtHostDebugServiceShape {
}
if (adapterProvider) {
const adapterExecutable = ExecutableDebugAdapter.platformAdapterExecutable(this._extensionService.getAllExtensionDescriptions(), session.type);
return asThenable(() => adapterProvider.provideDebugAdapter(session, adapterExecutable, CancellationToken.None));
return asThenable(() => adapterProvider.provideDebugAdapter(session, this.daExecutableFromPackage(session), CancellationToken.None));
}
// try deprecated command based extension API "adapterExecutableCommand" to determine the executable
......@@ -734,7 +731,12 @@ export class ExtHostDebugService implements ExtHostDebugServiceShape {
}
// fallback: use executable information from package.json
return Promise.resolve(ExecutableDebugAdapter.platformAdapterExecutable(this._extensionService.getAllExtensionDescriptions(), session.type));
return Promise.resolve(this.daExecutableFromPackage(session));
}
private daExecutableFromPackage(session: ExtHostDebugSession): DebugAdapterExecutable {
const dae = ExecutableDebugAdapter.platformAdapterExecutable(this._extensionService.getAllExtensionDescriptions(), session.type);
return new DebugAdapterExecutable(dae.command, dae.args, dae.env, dae.cwd);
}
private startBreakpoints() {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册