Fixes #48260: workspace.fetchTasks throws a TypeError

This commit is contained in:
Dirk Baeumer
2018-04-25 15:02:09 +02:00
parent aa63600dd2
commit d3f749b35d
5 changed files with 17 additions and 21 deletions

View File

@@ -610,7 +610,7 @@ namespace TaskDTO {
scope = value.scope.uri.toJSON();
}
}
if (!execution || !definition || !scope) {
if (!definition || !scope) {
return undefined;
}
let group = (value.group as types.TaskGroup) ? (value.group as types.TaskGroup).id : undefined;
@@ -655,7 +655,7 @@ namespace TaskDTO {
scope = types.TaskScope.Workspace;
}
}
if (!execution || !definition || !scope) {
if (!definition || !scope) {
return undefined;
}
let result = new types.Task(definition, scope, value.name, value.source.label, execution, value.problemMatchers);