fix: bigInt (#472)

This commit is contained in:
Cas
2023-06-07 17:44:34 +01:00
committed by GitHub
parent a6bb919268
commit d7061f73b2
+1 -1
View File
@@ -323,7 +323,7 @@ function toUInt64 (n) {
if (n > MAX_UINT || typeof n === 'string') {
const buf = new Uint8Array(8)
const view = new DataView(buf.buffer)
view.setBigUint64(0, n)
view.setBigUint64(0, BigInt(n))
return buf
}
return concat([new Uint8Array(4), common.toUInt32(n)])