mirror of
https://github.com/n8n-io/n8n.git
synced 2024-12-25 20:54:07 -08:00
fix(public-api): Create correct OAuth2 credential schema (#4111)
This commit is contained in:
parent
0ab89ad5d6
commit
28ab4f66f0
2
packages/cli/src/PublicApi/types.d.ts
vendored
2
packages/cli/src/PublicApi/types.d.ts
vendored
|
@ -152,7 +152,7 @@ export interface IRequired {
|
|||
}
|
||||
export interface IDependency {
|
||||
if?: { properties: {} };
|
||||
then?: { oneOf: IRequired[] };
|
||||
then?: { allOf: IRequired[] };
|
||||
else?: { allOf: IRequired[] };
|
||||
}
|
||||
|
||||
|
|
|
@ -220,7 +220,7 @@ export function toJsonSchema(properties: INodeProperties[]): IDataObject {
|
|||
},
|
||||
},
|
||||
then: {
|
||||
oneOf: [],
|
||||
allOf: [],
|
||||
},
|
||||
else: {
|
||||
allOf: [],
|
||||
|
@ -228,7 +228,7 @@ export function toJsonSchema(properties: INodeProperties[]): IDataObject {
|
|||
};
|
||||
}
|
||||
|
||||
propertyRequiredDependencies[dependantName].then?.oneOf.push({ required: [property.name] });
|
||||
propertyRequiredDependencies[dependantName].then?.allOf.push({ required: [property.name] });
|
||||
propertyRequiredDependencies[dependantName].else?.allOf.push({
|
||||
not: { required: [property.name] },
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue