diff --git a/src/sha3.js b/src/sha3.js index 3235233..362aade 100644 --- a/src/sha3.js +++ b/src/sha3.js @@ -106,7 +106,7 @@ Keccak.prototype.update = function (message) { var notString = typeof message != 'string'; - if (notString && message.constructor == root.ArrayBuffer) { + if (notString && message instanceof ArrayBuffer) { message = new Uint8Array(message); } var length = message.length, blocks = this.blocks, byteCount = this.byteCount,