From e979dd4f12634a72ee50989d7dd6a6852fa149fa Mon Sep 17 00:00:00 2001 From: Kyle Spearrin Date: Mon, 1 Apr 2019 14:31:42 -0400 Subject: [PATCH] make blob first --- src/services/cipher.service.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/services/cipher.service.ts b/src/services/cipher.service.ts index 957feedc46..c737299eac 100644 --- a/src/services/cipher.service.ts +++ b/src/services/cipher.service.ts @@ -569,8 +569,8 @@ export class CipherService implements CipherServiceAbstraction { const fd = new FormData(); try { - fd.append('key', dataEncKey[1].encryptedString); const blob = new Blob([encData], { type: 'application/octet-stream' }); + fd.append('key', dataEncKey[1].encryptedString); fd.append('data', blob, encFileName.encryptedString); } catch (e) { if (Utils.isNode && !Utils.isBrowser) { @@ -808,8 +808,8 @@ export class CipherService implements CipherServiceAbstraction { const fd = new FormData(); try { - fd.append('key', dataEncKey[1].encryptedString); const blob = new Blob([encData], { type: 'application/octet-stream' }); + fd.append('key', dataEncKey[1].encryptedString); fd.append('data', blob, encFileName.encryptedString); } catch (e) { if (Utils.isNode && !Utils.isBrowser) {