memx 0.3.41 → 0.3.43
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/client.cjs +2 -2
- package/dist/client.mjs +2 -2
- package/package.json +2 -2
- package/src/client.ts +2 -2
package/dist/client.cjs
CHANGED
|
@@ -132,10 +132,10 @@ function fromBuffer(result) {
|
|
|
132
132
|
result.recycle();
|
|
133
133
|
}
|
|
134
134
|
}
|
|
135
|
-
function makeTypedArray(
|
|
135
|
+
function makeTypedArray(Constructor, source) {
|
|
136
136
|
const clone = Buffer.from(source);
|
|
137
137
|
const { buffer, byteOffset, byteLength } = clone;
|
|
138
|
-
return new
|
|
138
|
+
return new Constructor(buffer, byteOffset, byteLength / Constructor.BYTES_PER_ELEMENT);
|
|
139
139
|
}
|
|
140
140
|
var MemxClient = class _MemxClient {
|
|
141
141
|
#adapter;
|
package/dist/client.mjs
CHANGED
|
@@ -98,10 +98,10 @@ function fromBuffer(result) {
|
|
|
98
98
|
result.recycle();
|
|
99
99
|
}
|
|
100
100
|
}
|
|
101
|
-
function makeTypedArray(
|
|
101
|
+
function makeTypedArray(Constructor, source) {
|
|
102
102
|
const clone = Buffer.from(source);
|
|
103
103
|
const { buffer, byteOffset, byteLength } = clone;
|
|
104
|
-
return new
|
|
104
|
+
return new Constructor(buffer, byteOffset, byteLength / Constructor.BYTES_PER_ELEMENT);
|
|
105
105
|
}
|
|
106
106
|
var MemxClient = class _MemxClient {
|
|
107
107
|
#adapter;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "memx",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.43",
|
|
4
4
|
"description": "Simple and fast memcached client",
|
|
5
5
|
"main": "./dist/index.cjs",
|
|
6
6
|
"module": "./dist/index.mjs",
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
"url": "git+ssh://git@github.com/juitnow/memx.git"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|
|
39
|
-
"@plugjs/build": "^0.7.
|
|
39
|
+
"@plugjs/build": "^0.7.6",
|
|
40
40
|
"@types/memjs": "^1.3.3",
|
|
41
41
|
"memjs": "^1.3.2"
|
|
42
42
|
},
|
package/src/client.ts
CHANGED
|
@@ -122,12 +122,12 @@ function fromBuffer<T extends Serializable>(result: AdapterResult): ClientResult
|
|
|
122
122
|
|
|
123
123
|
/** Create a {@link NodeJS.TypedArray} copying the contents of its source {@link Buffer} */
|
|
124
124
|
function makeTypedArray<T extends NodeJS.TypedArray>(
|
|
125
|
-
|
|
125
|
+
Constructor: TypedArrayConstructor<T>,
|
|
126
126
|
source: Buffer,
|
|
127
127
|
): T {
|
|
128
128
|
const clone = Buffer.from(source)
|
|
129
129
|
const { buffer, byteOffset, byteLength } = clone
|
|
130
|
-
return new
|
|
130
|
+
return new Constructor(buffer, byteOffset, byteLength / Constructor.BYTES_PER_ELEMENT)
|
|
131
131
|
}
|
|
132
132
|
|
|
133
133
|
/* ========================================================================== */
|