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

myzod

Package Overview
Dependencies
Maintainers
1
Versions
92
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

myzod - npm Package Compare versions

Comparing version 1.10.1 to 1.10.2

22

libs/types.js

@@ -101,2 +101,18 @@ "use strict";

}
function flattenCollectedErrorsTreeIntoMessages(collectedErrors, path = []) {
const messages = [];
for (const [key, value] of Object.entries(collectedErrors)) {
if (value === undefined) {
continue;
}
const newPath = [...path, key];
if (value.collectedErrors) {
messages.push(...flattenCollectedErrorsTreeIntoMessages(value.collectedErrors, newPath));
}
else {
messages.push(`error parsing object at path: "${prettyPrintPath(newPath)}" - ${value.message}`);
}
}
return messages;
}
class ValidationError extends Error {

@@ -106,5 +122,3 @@ // @ts-ignore

if (collectedErrors !== undefined) {
message = Object.values(collectedErrors)
.map(err => `error parsing object at path: "${prettyPrintPath((err === null || err === void 0 ? void 0 : err.path) || [])}" - ${err === null || err === void 0 ? void 0 : err.message}`)
.join('\n');
message = flattenCollectedErrorsTreeIntoMessages(collectedErrors).join('\n');
}

@@ -556,3 +570,3 @@ super(message);

: `error parsing object at path: "${prettyPrintPath(path)}" - ${err.message}`;
return new ValidationError(msg, path);
return new ValidationError(msg, path, err.collectedErrors);
}

@@ -559,0 +573,0 @@ selectParser() {

2

package.json
{
"name": "myzod",
"version": "1.10.1",
"version": "1.10.2",
"description": "",

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

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