Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

openapi-diff

Package Overview
Dependencies
Maintainers
3
Versions
36
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

openapi-diff - npm Package Compare versions

Comparing version 0.23.5 to 0.23.6

bin/build-yarn.sh

4

CHANGELOG.md

@@ -0,1 +1,5 @@

## [0.23.6](https://bitbucket.org/atlassian/openapi-diff/compare/0.23.5...0.23.6) (2022-08-04)
## [0.23.5](https://bitbucket.org/atlassian/openapi-diff/compare/0.23.4...0.23.5) (2021-10-11)

@@ -2,0 +6,0 @@

34

dist/openapi-diff/resource-loader/http-client.js
"use strict";
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
return new (P || (P = Promise))(function (resolve, reject) {
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
step((generator = generator.apply(thisArg, _arguments || [])).next());
});
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.HttpClient = void 0;
const request = require("request");
const axios_1 = require("axios");
const VError = require("verror");
class HttpClient {
get(location) {
return new Promise((resolve, reject) => {
request.get(location, (error, response, body) => {
if (error) {
reject(new VError(error, `ERROR: unable to open "${location}"`));
}
else if (response.statusCode !== 200) {
reject(new VError(error, `ERROR: unable to fetch "${location}". Response code: ${response.statusCode}`));
}
else {
resolve(body);
}
});
return __awaiter(this, void 0, void 0, function* () {
try {
const response = yield axios_1.default.get(location, {
transformResponse: (data) => data,
validateStatus: (status) => status === 200
});
return response.data;
}
catch (error) {
throw new VError(error, `ERROR: unable to fetch "${location}"`);
}
});

@@ -21,0 +29,0 @@ }

{
"name": "openapi-diff",
"version": "0.23.5",
"version": "0.23.6",
"description": "A CLI tool to identify differences between Swagger/OpenAPI specs.",

@@ -66,2 +66,3 @@ "bin": {

"dependencies": {
"axios": "^0.24.0",
"commander": "^8.2.0",

@@ -73,3 +74,2 @@ "js-yaml": "^4.0.0",

"openapi3-ts": "^2.0.0",
"request": "^2.88.2",
"swagger-parser": "^10.0.2",

@@ -76,0 +76,0 @@ "verror": "^1.10.0"

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc