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

object-unpacker

Package Overview
Dependencies
Maintainers
1
Versions
25
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

object-unpacker - npm Package Compare versions

Comparing version 0.0.15 to 0.0.16

5

dist/ObjectUnpacker.js

@@ -248,3 +248,6 @@ "use strict";

if (isAbsoluteReferenceOrNonReference(newValueStr)) {
result[returnKey] = referencesResolver.resolve(augmentedDictionary, newValue);
var extendedDictionary_1 = new Map();
augmentedDictionary.forEach(function (v, k) { return extendedDictionary_1.set(k, v); });
Util_1.indexObject(prefix, postfix, postfixIsOptional, '', extendedDictionary_1, data);
result[returnKey] = referencesResolver.resolve(extendedDictionary_1, newValue);
}

@@ -251,0 +254,0 @@ else if (newValueStr.includes('%self')) {

14

dist/ReferencesResolver.js

@@ -91,3 +91,3 @@ "use strict";

var replacement = referenceValues.get(ref);
if (replacement && typeof result === 'string') {
if (replacement !== null && replacement !== undefined && typeof result === 'string') {
if (result === ref) {

@@ -97,3 +97,10 @@ result = replacement;

else {
result = result.replace(ref, "" + replacement);
if (typeof replacement === 'object') {
var rawRef = unref(ref);
console.error(rawRef + " refers to an object or array and cannot be embedded in a string");
result = result.replace(ref, "" + rawRef);
}
else {
result = result.replace(ref, "" + replacement);
}
}

@@ -113,2 +120,5 @@ }

};
var unref = function (ref) {
return ref.replace('/index.', '').replace('/subs.', '');
};
//# sourceMappingURL=ReferencesResolver.js.map
{
"name": "object-unpacker",
"version": "0.0.15",
"version": "0.0.16",
"description": "A JSON to JSON mapper in TypeScript",

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

Sorry, the diff of this file is not supported yet

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