-
Notifications
You must be signed in to change notification settings - Fork 355
Closed
Description
Hi! 👋
Firstly, thanks for your work on this project! 🙂
Today I used patch-package to patch @omnigraph/[email protected] for the project I'm working on.
Here is the diff that solved my problem:
diff --git a/node_modules/@omnigraph/openapi/cjs/getJSONSchemaOptionsFromOpenAPIOptions.js b/node_modules/@omnigraph/openapi/cjs/getJSONSchemaOptionsFromOpenAPIOptions.js
index 2582e65..38b4f3b 100644
--- a/node_modules/@omnigraph/openapi/cjs/getJSONSchemaOptionsFromOpenAPIOptions.js
+++ b/node_modules/@omnigraph/openapi/cjs/getJSONSchemaOptionsFromOpenAPIOptions.js
@@ -63,6 +63,12 @@ async function getJSONSchemaOptionsFromOpenAPIOptions(name, { source, fallbackFo
continue;
}
const methodObj = pathObj[method];
+
+ if(typeof methodObj !== 'object') {
+ logger.warn(`Skipping ${method} ${relativePath} because it is not an object`);
+ continue;
+ }
+
const operationConfig = {
method: method.toUpperCase(),
path: relativePath,This issue body was partially generated by patch-package.
Metadata
Metadata
Assignees
Labels
No labels