memory-pager
Advanced tools
Comparing version 1.0.2 to 1.0.3
@@ -25,8 +25,11 @@ module.exports = Pager | ||
Pager.prototype.get = function (i, noMutate) { | ||
if (i >= this.pages.length) this.pages = grow(this.pages, i, this.length) | ||
Pager.prototype.get = function (i, noAllocate) { | ||
if (i >= this.pages.length) { | ||
if (noAllocate) return | ||
this.pages = grow(this.pages, i, this.length) | ||
} | ||
var page = this.pages[i] | ||
if (!page && !noMutate) { | ||
if (!page && !noAllocate) { | ||
page = this.pages[i] = new Page(i, alloc(this.pageSize)) | ||
@@ -33,0 +36,0 @@ if (i >= this.length) this.length = i + 1 |
{ | ||
"name": "memory-pager", | ||
"version": "1.0.2", | ||
"version": "1.0.3", | ||
"description": "Access memory using small fixed sized buffers", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
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
6511
131