提交 8a1dc6e1 编写于 作者: A Alex Ross

tasks.json validation issue

Fixes #68006
上级 52088458
......@@ -358,7 +358,11 @@ TaskDefinitionRegistry.onReady().then(() => {
};
if (taskType.required) {
schema.required = taskType.required.slice();
} else {
schema.required = [];
}
// Customized tasks require that the task type be set.
schema.required.push('type');
if (taskType.properties) {
for (let key of Object.keys(taskType.properties)) {
let property = taskType.properties[key];
......@@ -375,6 +379,10 @@ customize.properties!.customize = {
type: 'string',
deprecationMessage: nls.localize('JsonSchema.tasks.customize.deprecated', 'The customize property is deprecated. See the 1.14 release notes on how to migrate to the new task customization approach')
};
if (!customize.required) {
customize.required = [];
}
customize.required.push('customize');
taskDefinitions.push(customize);
let definitions = Objects.deepClone(commonSchemaDefinitions);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册