diff --git a/package.json b/package.json index f21ab95..bf63e2e 100644 --- a/package.json +++ b/package.json @@ -26,7 +26,8 @@ "./util/immediate.js": "./util/immediate-browser.js" }, "dependencies": { - "abstract-leveldown": "~6.2.1", + "abstract-leveldown": "~6.2.3", + "buffer": "^5.5.0", "immediate": "~3.2.3", "inherits": "^2.0.3", "ltgt": "^2.1.2" diff --git a/util/deserialize.js b/util/deserialize.js index b999b54..f54c8f6 100644 --- a/util/deserialize.js +++ b/util/deserialize.js @@ -1,5 +1,6 @@ 'use strict' +var Buffer = require('buffer').Buffer var ta2str = (function () { if (global.TextDecoder) { var decoder = new TextDecoder('utf-8') diff --git a/util/serialize.js b/util/serialize.js index 73d25ff..8fa0f0a 100644 --- a/util/serialize.js +++ b/util/serialize.js @@ -1,5 +1,6 @@ 'use strict' +var Buffer = require('buffer').Buffer // Returns either a Uint8Array or Buffer (doesn't matter to // IndexedDB, because Buffer is a subclass of Uint8Array) var str2bin = (function () { diff --git a/util/support.js b/util/support.js index e9116ca..7b90211 100644 --- a/util/support.js +++ b/util/support.js @@ -1,5 +1,7 @@ 'use strict' +var Buffer = require('buffer').Buffer + exports.test = function (key) { return function test (impl) { try {