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

manyfest

Package Overview
Dependencies
Maintainers
1
Versions
38
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

manyfest - npm Package Compare versions

Comparing version 1.0.37 to 1.0.38

2

package.json
{
"name": "manyfest",
"version": "1.0.37",
"version": "1.0.38",
"description": "JSON Object Manifest for Data Description and Parsing",

@@ -5,0 +5,0 @@ "main": "source/Manyfest.js",

@@ -50,5 +50,15 @@ /**

// Make sure pObject (the object we are meant to be recursing) is an object (which could be an array or object)
if (typeof(pObject) != 'object') return undefined;
if (typeof(pObject) != 'object')
{
return undefined;
}
if (pObject === null)
{
return undefined;
}
// Make sure pAddress (the address we are resolving) is a string
if (typeof(pAddress) != 'string') return undefined;
if (typeof(pAddress) != 'string')
{
return undefined;
}
// Stash the parent address for later resolution

@@ -339,3 +349,3 @@ let tmpParentAddress = "";

{
return undefined;
return null;
}

@@ -342,0 +352,0 @@ }

@@ -47,2 +47,21 @@ /**

(
'Javascript null values should not cause errors..',
(fTestComplete)=>
{
let _Manyfest = new libManyfest({ Scope:'Archive.org', Descriptors: {'metadata.creator': {Name:'Creator', Hash:'Creator'}}});
let tmpNullSampleData = JSON.parse(JSON.stringify(_SampleDataArchiveOrgFrankenberry));
tmpNullSampleData.Noel = null;
let tmpNullValue = _Manyfest.getValueAtAddress(tmpNullSampleData, 'Noel');
let tmpNullValueOneDeep = _Manyfest.getValueAtAddress(tmpNullSampleData, 'Noel.SomeChildValue');
let tmpNullValueTwoDeep = _Manyfest.getValueAtAddress(tmpNullSampleData, 'Noel.SomeChildValue.SecondTier');
let tmpNullValueTwoDeepObject = _Manyfest.getValueAtAddress(tmpNullSampleData, 'Noel.SomeChildValue[SecondTier]');
let tmpNullValueTwoDeepArray = _Manyfest.getValueAtAddress(tmpNullSampleData, 'Noel.SomeChildValue.SecondTier[0]');
Expect(tmpNullValue).to.equal(null);
Expect(tmpNullValueOneDeep).to.equal(undefined);
Expect(tmpNullValueTwoDeep).to.equal(undefined);
fTestComplete();
}
);
test
(
'It should be trivial to access subproperties with a schema by hash.',

@@ -49,0 +68,0 @@ (fTestComplete)=>

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