sodium_memcmp returns boolean
This commit is contained in:
parent
9b78e675e4
commit
b7a0d1f2e5
@ -23,5 +23,5 @@ function crypto_verify_32(x, xi, y, yi) {
|
||||
function sodium_memcmp (a, b) {
|
||||
assert(a.byteLength = b.byteLength, 'buffers must be the same size')
|
||||
|
||||
return vn(a, 0, b, 0, a.byteLength)
|
||||
return vn(a, 0, b, 0, a.byteLength) === 0
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user