Merge pull request #9966 from Meai1/patch-3
Check if adapter is null and let it print errors
This commit is contained in:
commit
30c71c5d85
|
@ -297,9 +297,12 @@ export class ConfigurationManager implements debug.IConfigurationManager {
|
|||
|
||||
const factory: { (): TPromise<any> }[] = Object.keys(interactiveVariablesToSubstitutes).map(interactiveVariable => {
|
||||
return () => {
|
||||
const commandId = this.adapter.variables ? this.adapter.variables[interactiveVariable] : null;
|
||||
let commandId = null;
|
||||
if (this.adapter !== null) {
|
||||
commandId = this.adapter.variables ? this.adapter.variables[interactiveVariable] : null;
|
||||
}
|
||||
if (!commandId) {
|
||||
return TPromise.wrapError(nls.localize('interactiveVariableNotFound', "Adapter {0} does not contribute variable {1} that is specified in launch configuration.", this.adapter.type, interactiveVariable));
|
||||
return TPromise.wrapError(nls.localize('interactiveVariableNotFound', "Adapter {0} does not contribute variable {1} that is specified in launch configuration.", this.adapter !== null ? this.adapter.type : null, interactiveVariable));
|
||||
} else {
|
||||
return this.commandService.executeCommand<string>(commandId, this.configuration).then(result => {
|
||||
if (!result) {
|
||||
|
|
Loading…
Reference in a new issue