New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

openapi-enforcer

Package Overview
Dependencies
Maintainers
1
Versions
131
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

openapi-enforcer - npm Package Compare versions

Comparing version 1.14.1 to 1.14.2

2

package.json
{
"name": "openapi-enforcer",
"version": "1.14.1",
"version": "1.14.2",
"description": "Library for validating, parsing, and formatting data against open api schemas.",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -186,4 +186,4 @@ /**

} else {
return value;
return value
}
}
const Exception = require('../exception');
const util = require('../util');
const SchemaValue = require('./value')

@@ -7,2 +8,3 @@ const m1 = 'Unable to determine deserialization schema because too many schemas match. Use of a discriminator or making your schemas more specific would help this problem.'

exports.anyOneOf = function (schema, value, exception, map, action, isSerialize, options) {
if (value instanceof SchemaValue) value = value.value
const key = schema.anyOf ? 'anyOf' : 'oneOf';

@@ -34,3 +36,3 @@ const exceptions = [];

const properties = subSchema.properties || {};
const keys = Object.keys(value);
const keys = Object.keys(result);
const length = keys.length;

@@ -48,3 +50,3 @@ for (let i = 0; i < length; i++) {

if (score > 0 && !isSerialize && subSchema.validate(result)) score = 0;
if (score > 0) matches.push({ score, result })
if (score > 0) matches.push({ score, result: util.copy(result) })
}

@@ -51,0 +53,0 @@ });

Sorry, the diff of this file is too big to display

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