Skip to content

Commit f991dc1

Browse files
sevenwithawpcjihrig
authored andcommitted
fix(node/zlib) zlib codes contains undefined values and keys (#2396)
1 parent 82a911d commit f991dc1

File tree

3 files changed

+3
-2
lines changed

3 files changed

+3
-2
lines changed

node/_pako.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1460,7 +1460,7 @@ var constants$2 = {
14601460
Z_DATA_ERROR: -3,
14611461
Z_MEM_ERROR: -4,
14621462
Z_BUF_ERROR: -5,
1463-
//Z_VERSION_ERROR: -6,
1463+
Z_VERSION_ERROR: -6,
14641464

14651465
/* compression levels */
14661466
Z_NO_COMPRESSION: 0,

node/_zlib.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ export const codes = Object.freeze({
3434
[binding.Z_DATA_ERROR]: "Z_DATA_ERROR",
3535
[binding.Z_MEM_ERROR]: "Z_MEM_ERROR",
3636
[binding.Z_BUF_ERROR]: "Z_BUF_ERROR",
37-
[binding.Z_VERSION_ERRO]: "Z_VERSION_ERROR",
37+
[binding.Z_VERSION_ERROR]: "Z_VERSION_ERROR",
3838
});
3939

4040
export const createDeflate = function (o) {

node/_zlib_binding.mjs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ export const Z_STREAM_ERROR = constants.Z_STREAM_ERROR;
2222
export const Z_DATA_ERROR = constants.Z_DATA_ERROR;
2323
export const Z_MEM_ERROR = constants.Z_MEM_ERROR;
2424
export const Z_BUF_ERROR = constants.Z_BUF_ERROR;
25+
export const Z_VERSION_ERROR = constants.Z_VERSION_ERROR;
2526
export const Z_NO_COMPRESSION = constants.Z_NO_COMPRESSION;
2627
export const Z_BEST_SPEED = constants.Z_BEST_SPEED;
2728
export const Z_BEST_COMPRESSION = constants.Z_BEST_COMPRESSION;

0 commit comments

Comments
 (0)