summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorDavid Mehren2021-04-26 21:30:06 +0200
committerGitHub2021-04-26 21:30:06 +0200
commit7ea3357ba846127b6e3d63fa0722de9be2957a7f (patch)
tree81130c2bd702b5bd3dd2834c9a157b43779c6488 /lib
parent09466189ad0d4020059ec56486d05dcb135fd7e1 (diff)
parent0a1bf3ca1dd8c6558a13d27b389e7e96359a01b9 (diff)
Merge pull request #1201 from hedgedoc/remove-polyfill
Diffstat (limited to 'lib')
-rw-r--r--lib/models/user.js9
1 files changed, 0 insertions, 9 deletions
diff --git a/lib/models/user.js b/lib/models/user.js
index 26a557a7..383be1a7 100644
--- a/lib/models/user.js
+++ b/lib/models/user.js
@@ -1,15 +1,6 @@
'use strict'
// external modules
const Sequelize = require('sequelize')
-const crypto = require('crypto')
-if (!crypto.scrypt) {
- // polyfill for node.js 8.0, see https://github.com/chrisveness/scrypt-kdf#openssl-implementation
- const scryptAsync = require('scrypt-async')
- crypto.scrypt = function (password, salt, keylen, options, callback) {
- const opt = Object.assign({}, options, { dkLen: keylen })
- scryptAsync(password, salt, opt, (derivedKey) => callback(null, Buffer.from(derivedKey)))
- }
-}
const scrypt = require('scrypt-kdf')
// core