Open-Source API Development Ecosystem • https://hoppscotch.io • Offline, On-Prem & Cloud • Web, Desktop & CLI • Open-Source Alternative to Postman, Insomnia
TypeScript apiapi-clientapi-restapi-testingdeveloper-toolsgraphqlhttphttp-clientpwarestrest-apispatestingtesting-toolstoolsvuevuejswebsocket
fix: support patch in openapi, fixes 2138
Andrew Bastinfda9f2e84246
diff --git a/packages/hoppscotch-app/helpers/import-export/import/openapi.ts b/packages/hoppscotch-app/helpers/import-export/import/openapi.tsindex 6d76c4e26..2d25f09ba 100644--- a/packages/hoppscotch-app/helpers/import-export/import/openapi.ts+++ b/packages/hoppscotch-app/helpers/import-export/import/openapi.ts@@ -519,7 +519,7 @@ const convertPathToHoppReqs = (pathObj: OpenAPIPathInfoType) =>pipe(- ["get", "head", "post", "put", "delete", "options"] as const,+ ["get", "head", "post", "put", "delete", "options", "patch"] as const,// Filter and map out path infoRA.filterMap(@@ -538,10 +538,10 @@ const convertPathToHoppReqs = (// We don't need to worry about reference types as the Dereferencing pass should remove themparams: parseOpenAPIParams(- (info.parameters as OpenAPIParamsType[]) ?? []+ (info.parameters as OpenAPIParamsType[] | undefined) ?? []),headers: parseOpenAPIHeaders(- (info.parameters as OpenAPIParamsType[]) ?? []+ (info.parameters as OpenAPIParamsType[] | undefined) ?? []),auth: parseOpenAPIAuth(doc, info),