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

@hestia-earth/schema-convert

Package Overview
Dependencies
Maintainers
1
Versions
136
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@hestia-earth/schema-convert - npm Package Compare versions

Comparing version 7.7.1 to 7.8.0

7

json.js

@@ -197,6 +197,9 @@ "use strict";

* If the user provided a non-object where an object was expected, assume it was meant to be the `name` property.
* For non-Terms, we assume it is the `id`.
*
* @param value The value mapped as a Ref
*/
var schemaRefValue = function (value) { return typeof value === 'object' ? value : ({ name: value }); };
var schemaRefValue = function (value, schemaType) {
return typeof value === 'object' ? value : schemaType === schema_1.SchemaType.Term ? { name: value } : { id: value };
};
exports.cleanStringValue = function (value) { return (value.match(/^[\d]+\.[\d]+\.[\d]+$/) === null ? value.replace(/\.0$/, '') : value).trim(); };

@@ -252,3 +255,3 @@ var propertyTypeToValue = {

var schema = schemaType ? schemas[schemaType] : undefined;
var data = schema ? mapContent(schemas, schema, _i)(schemaRefValue(value)) : safeParseJSON(value);
var data = schema ? mapContent(schemas, schema, _i)(schemaRefValue(value, schemaType)) : safeParseJSON(value);
return utils_1.isEmpty(data) ? {} : (schema ? extendDataFromSchema(data, schema, schemaType, _i) : data);

@@ -255,0 +258,0 @@ }

{
"name": "@hestia-earth/schema-convert",
"version": "7.7.1",
"version": "7.8.0",
"description": "Hestia Schema Converters",

@@ -5,0 +5,0 @@ "main": "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