Comparing version 2.2.0 to 2.2.1
@@ -30,3 +30,3 @@ module.exports = function (max) { | ||
if(v !== undefined) return v | ||
if(v = _cache[key]) { | ||
if((v = _cache[key]) !== undefined) { | ||
update(key, v) | ||
@@ -33,0 +33,0 @@ return v |
{ | ||
"name": "hashlru", | ||
"description": "simpler faster substitute for LRU", | ||
"version": "2.2.0", | ||
"version": "2.2.1", | ||
"homepage": "https://github.com/dominictarr/hashlru", | ||
@@ -6,0 +6,0 @@ "repository": { |
@@ -32,3 +32,3 @@ # hashlru | ||
This algorithm does not give you an ordered list of the N most recently used items, | ||
but you do not really need that! The property of dropping the lest recent items is still preserved. | ||
but you do not really need that! The property of dropping the least recent items is still preserved. | ||
@@ -76,5 +76,5 @@ see a [benchmark](https://github.com/dominictarr/bench-lru) of this against | ||
### lru.get (key) => value | null | ||
### lru.get (key) => value | undefined | ||
Returns the value in the cache. | ||
Returns the value in the cache, or `undefined` if the value is not in the cache. | ||
@@ -81,0 +81,0 @@ ### lru.set(key, value) |
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
8405