Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,6 @@
"@types/electron-store": "^3.2.0",
"@types/express": "^4.17.3",
"@types/file-saver": "^2.0.5",
"@types/gzip-js": "^0.3.3",
"@types/html-entities": "^1.3.4",
"@types/ioredis": "^4.26.0",
"@types/is-glob": "^4.0.2",
Expand Down Expand Up @@ -239,7 +238,6 @@
"formik": "^2.2.9",
"fzstd": "^0.1.0",
"get-port": "^7.0.0",
"gzip-js": "^0.3.2",
"html-entities": "^2.3.2",
"html-react-parser": "^1.2.4",
"java-object-serialization": "^0.1.2",
Expand Down Expand Up @@ -289,4 +287,4 @@
"browser": {
"uuid": "./node_modules/uuid/dist/esm-browser/index.js"
}
}
}
5 changes: 2 additions & 3 deletions redisinsight/ui/src/utils/decompressors/decompressors.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
import { forIn } from 'lodash'
import { unzip } from 'gzip-js'
import { decompress as decompressFzstd } from 'fzstd'
// @ts-ignore
import { decompress as decompressLz4 } from 'lz4js'
import { decompress as decompressSnappy } from '@stablelib/snappy'
// @ts-ignore
import { decompress as decompressBrotli } from 'brotli-unicode/js'
import { inflate } from 'pako'
import { inflate, ungzip } from 'pako'
import { COMPRESSOR_MAGIC_SYMBOLS, ICompressorMagicSymbols, KeyValueCompressor } from 'uiSrc/constants'
import { RedisResponseBuffer, RedisString } from 'uiSrc/slices/interfaces'
import { anyToBuffer, bufferToString, bufferToUint8Array, isEqualBuffers, Nullable } from 'uiSrc/utils'
Expand All @@ -24,7 +23,7 @@ const decompressingBuffer = (
try {
switch (compressor) {
case KeyValueCompressor.GZIP: {
const value = unzip(Buffer.from(reply))
const value = ungzip(Buffer.from(reply))

return {
compressor,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ describe('decompressingBuffer', () => {
const result = decompressingBuffer(input, compressorInit || compressor)
let value: UintArray = output

if (compressor && compressor !== KeyValueCompressor.GZIP) {
if (compressor) {
value = new Uint8Array(output)
}

Expand Down
25 changes: 0 additions & 25 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2682,13 +2682,6 @@
dependencies:
"@types/node" "*"

"@types/gzip-js@^0.3.3":
version "0.3.3"
resolved "https://registry.yarnpkg.com/@types/gzip-js/-/gzip-js-0.3.3.tgz#b485ce6f007c57fbac9ea7256c30f437ceb5fa1a"
integrity sha512-Bp4dv9hfpD49sjn59+8VPMDm4O5Lx1qSLKn4GqV9ENbvoKrCV7GntIr7e85cFjtRWRPTXkIxWTCk4DKMXostMg==
dependencies:
"@types/node" "*"

"@types/hast@^2.0.0":
version "2.3.4"
resolved "https://registry.yarnpkg.com/@types/hast/-/hast-2.3.4.tgz#8aa5ef92c117d20d974a82bdfb6a648b08c0bafc"
Expand Down Expand Up @@ -4794,11 +4787,6 @@ cosmiconfig@^8.1.3:
parse-json "^5.2.0"
path-type "^4.0.0"

"crc32@>= 0.2.2":
version "0.2.2"
resolved "https://registry.yarnpkg.com/crc32/-/crc32-0.2.2.tgz#7ad220d6ffdcd119f9fc127a7772cacea390a4ba"
integrity sha512-PFZEGbDUeoNbL2GHIEpJRQGheXReDody/9axKTxhXtQqIL443wnNigtVZO9iuCIMPApKZRv7k2xr8euXHqNxQQ==

crc@^3.8.0:
version "3.8.0"
resolved "https://registry.yarnpkg.com/crc/-/crc-3.8.0.tgz#ad60269c2c856f8c299e2c4cc0de4556914056c6"
Expand Down Expand Up @@ -5452,11 +5440,6 @@ define-properties@^1.1.3, define-properties@^1.1.4, define-properties@^1.2.0, de
has-property-descriptors "^1.0.0"
object-keys "^1.1.1"

"deflate-js@>= 0.2.2":
version "0.2.3"
resolved "https://registry.yarnpkg.com/deflate-js/-/deflate-js-0.2.3.tgz#f85abb58ebc5151a306147473d57c3e4f7e4426b"
integrity sha512-r5KgHJ/yTiWQs23nVeQz5dSL/kmW0MBszsssNyEqDCjjFDj4XG/c6QUN/I0JtY3ZHwwcaNBtGE8s+oV33acTfQ==

delaunator@5:
version "5.0.0"
resolved "https://registry.yarnpkg.com/delaunator/-/delaunator-5.0.0.tgz#60f052b28bd91c9b4566850ebf7756efe821d81b"
Expand Down Expand Up @@ -7186,14 +7169,6 @@ gunzip-maybe@^1.4.2:
pumpify "^1.3.3"
through2 "^2.0.3"

gzip-js@^0.3.2:
version "0.3.2"
resolved "https://registry.yarnpkg.com/gzip-js/-/gzip-js-0.3.2.tgz#23117efeeb28cf385248deff0dffad894836d96b"
integrity sha512-BFTiwtEN12koJsnhVo77SzW+u6VANzhaK0HEtdwFwgFzFOq1WQJ8eSPEyGAueUfs1C/WqdgtuYnUwCRuRm1A5Q==
dependencies:
crc32 ">= 0.2.2"
deflate-js ">= 0.2.2"

gzip-size@^6.0.0:
version "6.0.0"
resolved "https://registry.yarnpkg.com/gzip-size/-/gzip-size-6.0.0.tgz#065367fd50c239c0671cbcbad5be3e2eeb10e462"
Expand Down
Loading