diff --git a/www/common/common-hash.js b/www/common/common-hash.js index d5066b757..e089852cc 100644 --- a/www/common/common-hash.js +++ b/www/common/common-hash.js @@ -12,6 +12,7 @@ define([ var hexToBase64 = Util.hexToBase64; var base64ToHex = Util.base64ToHex; Hash.encodeBase64 = Nacl.util.encodeBase64; + Hash.decodeBase64 = Nacl.util.decodeBase64; // This implementation must match that on the server // it's used for a checksum diff --git a/www/common/common-messenger.js b/www/common/common-messenger.js index 081cd311f..b400d1dae 100644 --- a/www/common/common-messenger.js +++ b/www/common/common-messenger.js @@ -26,6 +26,15 @@ define([ return JSON.parse(JSON.stringify(o)); }; + var convertToUint8 = function (obj) { + var l = Object.keys(obj).length; + var u = new Uint8Array(l); + for (var i = 0; i