diff --git a/lib/models/user.js b/lib/models/user.js index 26a557a77..383be1a72 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