فهرست منبع

Fix schema definitions support

The 'Azure' provider has schema definitions which are used to render
object fields. This fixes an issue where those definitions wouldn't get
parsed.
Sergiu Miclea 6 سال پیش
والد
کامیت
6dca6d9e8e
1فایلهای تغییر یافته به همراه1 افزوده شده و 1 حذف شده
  1. 1 1
      src/sources/Schemas.js

+ 1 - 1
src/sources/Schemas.js

@@ -35,7 +35,7 @@ class SchemaParser {
   static optionsSchemaToFields(provider: string, schema: any) {
     let parser = OptionsSchemaPlugin[provider] || OptionsSchemaPlugin.default
     let schemaRoot = schema.oneOf ? schema.oneOf[0] : schema
-    let fields = parser.parseSchemaToFields(schemaRoot, schemaRoot.definitions)
+    let fields = parser.parseSchemaToFields(schemaRoot, schema.definitions)
     fields.sort((a, b) => {
       if (a.required && !b.required) {
         return -1