Skip to content

Commit

Permalink
Rollback hapi and inert (patch)
Browse files Browse the repository at this point in the history
  • Loading branch information
zrrrzzt committed May 3, 2020
1 parent a54f006 commit c4bee84
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions handlers/index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
'use strict'

const fs = require('fs')
const uuid = require('uuid')
const { v4: uuid } = require('uuid')
const unoconv = require('unoconv2')
const formats = require('../lib/data/formats.json')
const pkg = require('../package.json')
Expand All @@ -12,7 +12,7 @@ module.exports.handleUpload = (request, reply) => {
if (data.file) {
const nameArray = data.file.hapi.filename.split('.')
const fileEndingOriginal = nameArray.pop()
const temporaryName = uuid.v4()
const temporaryName = uuid()
const pathPre = process.cwd() + '/uploads/' + temporaryName
const fileNameTempOriginal = pathPre + '.' + fileEndingOriginal
const file = fs.createWriteStream(fileNameTempOriginal)
Expand Down Expand Up @@ -73,7 +73,7 @@ module.exports.showFormat = (request, reply) => {
}

module.exports.showVersions = (request, reply) => {
let versions = {}
const versions = {}
Object.keys(pkg.dependencies).forEach((item) => {
versions[item] = pkg.dependencies[item]
})
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"homepage": "https://github.com/zrrrzzt/tfk-api-unoconv",
"main": "index.js",
"engines": {
"node": ">=10.14.0"
"node": ">=10.20.1"
},
"scripts": {
"test": "standard && npm audit && tap --reporter=spec test/**/*.js",
Expand All @@ -30,8 +30,8 @@
"url": "git+https://github.com/zrrrzzt/tfk-api-unoconv.git"
},
"dependencies": {
"hapi": "18.1.0",
"inert": "5.1.3",
"hapi": "16.7.0",
"inert": "4.2.1",
"unoconv2": "1.0.0",
"uuid": "8.0.0"
},
Expand Down

0 comments on commit c4bee84

Please sign in to comment.