Comparing version 2.0.1 to 2.0.2
@@ -74,3 +74,7 @@ 'use strict'; | ||
k = uri.url + uri.hash.slice(0, i).join('/'); | ||
data = _store[k]; | ||
if (k === '#') { | ||
data = _root; | ||
} else { | ||
data = _store[k]; | ||
} | ||
} | ||
@@ -133,3 +137,3 @@ if (data) { | ||
return p.then(function () { | ||
return _parsePassTwo(obj, _scope + '/' + i); | ||
return _parsePassTwo(obj, _scope + '/' + key); | ||
}); | ||
@@ -136,0 +140,0 @@ }; |
{ | ||
"name": "jsonref", | ||
"version": "2.0.1", | ||
"version": "2.0.2", | ||
"description": "Javascript References ($ref) and Pointers library", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
@@ -58,4 +58,8 @@ import url from 'url'; | ||
for (var i = uri.hash.length, k ; !data && i > 0 ; i--) { | ||
k = uri.url + uri.hash.slice(0, i).join('/'); | ||
data = _store[k]; | ||
k = uri.url + uri.hash.slice(0, i).join('/') | ||
if (k === '#') { | ||
data = _root; | ||
} else { | ||
data = _store[k]; | ||
} | ||
} | ||
@@ -124,3 +128,3 @@ if (data) { | ||
return p.then(function() { | ||
return _parsePassTwo(obj, _scope + '/' + i); | ||
return _parsePassTwo(obj, _scope + '/' + key); | ||
}); | ||
@@ -127,0 +131,0 @@ } |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
57016
310