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

@trayio/commons

Package Overview
Dependencies
Maintainers
4
Versions
179
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@trayio/commons - npm Package Compare versions

Comparing version 2.9.0 to 2.10.0

1

dist/codec/RemoveNullValuesCodec.d.ts

@@ -9,4 +9,5 @@ import * as E from 'fp-ts/lib/Either';

private removeNullValuesIfPresent;
private removeNullFromArrayIfPresent;
private removeNullFromObjectIfPresent;
}
//# sourceMappingURL=RemoveNullValuesCodec.d.ts.map

@@ -45,4 +45,15 @@ "use strict";

}
if (Array.isArray(value)) {
return this.removeNullFromArrayIfPresent(value);
}
return value;
}
removeNullFromArrayIfPresent(value) {
return value.reduce((acc, propertyValue) => {
if (propertyValue == null) {
return acc;
}
return [...acc, this.removeNullValuesIfPresent(propertyValue)];
}, []);
}
removeNullFromObjectIfPresent(value) {

@@ -57,2 +68,6 @@ return Object.entries(value).reduce((acc, [key, propertyValue]) => {

}
if (Array.isArray(propertyValue)) {
const nestedArray = this.removeNullFromArrayIfPresent(propertyValue);
return Object.assign(Object.assign({}, acc), { [key]: nestedArray });
}
return Object.assign(Object.assign({}, acc), { [key]: propertyValue });

@@ -59,0 +74,0 @@ }, {});

2

package.json
{
"name": "@trayio/commons",
"version": "2.9.0",
"version": "2.10.0",
"description": "Extensions to the standard/core libraries and basic features",

@@ -5,0 +5,0 @@ "exports": {

Sorry, the diff of this file is not supported yet

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