reftools
Advanced tools
Comparing version 0.0.1 to 0.0.2
@@ -62,3 +62,3 @@ 'use strict'; | ||
if (setAndLast) { | ||
obj[components][i] = newValue; | ||
obj[components[i]] = newValue; | ||
} | ||
@@ -65,0 +65,0 @@ obj = obj[components[i]]; |
{ | ||
"name": "reftools", | ||
"version": "0.0.1", | ||
"version": "0.0.2", | ||
"description": "Utility functions to deal with references in objects", | ||
@@ -5,0 +5,0 @@ "main": "dereference.js", |
@@ -43,3 +43,5 @@ 'use strict'; | ||
should(jptr(obj,'#/name/-','*')).be.equal(false); | ||
should(jptr(obj,'#/name')).be.equal('obj'); // strings are immutable | ||
should(jptr(obj,'#/name')).be.equal('obj'); // strings are immutable as arrays | ||
should(jptr(obj,'#/name','obj*')).be.equal('obj*'); // string properties are mutable | ||
should(jptr(obj,'#/name')).be.equal('obj*'); | ||
should(jptr(obj,'#/age')).be.equal(false); | ||
@@ -46,0 +48,0 @@ should(jptr(obj,'#/x/y')).be.equal(false); |
23155
633