crypto.createHash -> create-hash, 2.7.3

closes #52
This commit is contained in:
Jannis R 2018-05-21 12:15:40 +02:00
parent c5aab72e71
commit 00b1eb387c
No known key found for this signature in database
GPG key ID: 0FE83946296A88A5
2 changed files with 4 additions and 3 deletions

View file

@ -1,6 +1,6 @@
'use strict'
const crypto = require('crypto')
const createHash = require('create-hash')
let captureStackTrace = () => {}
if (process.env.NODE_DEBUG === 'hafas-client') {
captureStackTrace = require('capture-stack-trace')
@ -9,7 +9,7 @@ const {stringify} = require('query-string')
const Promise = require('pinkie-promise')
const {fetch} = require('fetch-ponyfill')({Promise})
const md5 = input => crypto.createHash('md5').update(input).digest()
const md5 = input => createHash('md5').update(input).digest()
const request = (profile, data) => {
const body = profile.transformReqBody({lang: 'en', svcReqL: [data]})

View file

@ -1,7 +1,7 @@
{
"name": "hafas-client",
"description": "JavaScript client for HAFAS public transport APIs.",
"version": "2.7.2",
"version": "2.7.3",
"main": "index.js",
"files": [
"index.js",
@ -34,6 +34,7 @@
"dependencies": {
"@mapbox/polyline": "^1.0.0",
"capture-stack-trace": "^1.0.0",
"create-hash": "^1.2.0",
"fetch-ponyfill": "^6.0.0",
"gps-distance": "0.0.4",
"lodash": "^4.17.5",