mirror of
https://github.com/fluencelabs/js-libp2p-crypto
synced 2025-03-15 10:41:03 +00:00
fix: dont setimmediate when its not needed
This commit is contained in:
parent
87e8f1c86f
commit
9e5778694c
@ -10,9 +10,7 @@ exports.create = function (hash, secret, callback) {
|
||||
|
||||
hmac.update(data)
|
||||
|
||||
setImmediate(() => {
|
||||
cb(null, hmac.digest())
|
||||
})
|
||||
cb(null, hmac.digest())
|
||||
},
|
||||
length: lengths[hash]
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user