Skip to content

Commit

Permalink
fix(unzip): out dated dependency #139
Browse files Browse the repository at this point in the history
  • Loading branch information
polonel committed Jan 28, 2019
1 parent 282d725 commit b0aab01
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@
"tar": "4.4.8",
"thirty-two": "1.0.2",
"uglify-js": "3.4.9",
"unzip": "0.1.11",
"unzipper": "0.9.10",
"util": "0.11.1",
"webpack": "4.29.0",
"winston": "2.4.4"
Expand Down
4 changes: 2 additions & 2 deletions src/controllers/debug.js
Original file line number Diff line number Diff line change
Expand Up @@ -566,8 +566,8 @@ debugController.uploadPlugin = function (req, res) {
// Everything Checks out lets make sure the file exists and then add it to the attachments array
if (!fs.existsSync(object.filePath)) return res.status(500).send('File Failed to Save to Disk')

var unzip = require('unzip')
fs.createReadStream(object.filePath).pipe(unzip.Extract({ path: path.join(__dirname, '../../plugins') }))
var unzipper = require('unzipper')
fs.createReadStream(object.filePath).pipe(unzipper.Extract({ path: path.join(__dirname, '../../plugins') }))

return res.sendStatus(200)
})
Expand Down
4 changes: 2 additions & 2 deletions src/settings/defaults.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ function downloadWin32MongoDBTools (callback) {
) {
winston.debug('Windows platform detected. Downloading MongoDB Tools')
fs.emptyDirSync(savePath)
var unzip = require('unzip')
var unzipper = require('unzipper')
var file = fs.createWriteStream(path.join(savePath, filename))
http
.get('http://storage.trudesk.io/tools/' + filename, function (response) {
Expand All @@ -63,7 +63,7 @@ function downloadWin32MongoDBTools (callback) {
})
file.on('close', function () {
fs.createReadStream(path.join(savePath, filename))
.pipe(unzip.Extract({ path: savePath }))
.pipe(unzipper.Extract({ path: savePath }))
.on('close', function () {
fs.unlink(path.join(savePath, filename), callback)
})
Expand Down

0 comments on commit b0aab01

Please sign in to comment.