diff --git a/src/hat.js b/src/hat.js index a9cf00e42..e87c5b658 100644 --- a/src/hat.js +++ b/src/hat.js @@ -2,8 +2,8 @@ exports = module.exports = hat; -var crypto = require('crypto'); +const crypto = require('crypto'); -function hat (bits) { +function hat(bits) { return crypto.randomBytes(bits / 8).toString('hex'); }