removed debugging code
This commit is contained in:
parent
60567cc596
commit
e74689e8af
|
@ -195,10 +195,7 @@ class UploadService {
|
||||||
);
|
);
|
||||||
let backupedFile: BackupedFile = await this.uploadtoBucket(
|
let backupedFile: BackupedFile = await this.uploadtoBucket(
|
||||||
encryptedFile,
|
encryptedFile,
|
||||||
token,
|
token
|
||||||
worker,
|
|
||||||
encryptedKey,
|
|
||||||
collection.key
|
|
||||||
);
|
);
|
||||||
file = null;
|
file = null;
|
||||||
encryptedFile = null;
|
encryptedFile = null;
|
||||||
|
@ -376,29 +373,11 @@ class UploadService {
|
||||||
|
|
||||||
private async uploadtoBucket(
|
private async uploadtoBucket(
|
||||||
file: ProcessedFile,
|
file: ProcessedFile,
|
||||||
token: string,
|
token: string
|
||||||
worker,
|
|
||||||
enFilekey: B64EncryptionResult,
|
|
||||||
collectionKey
|
|
||||||
): Promise<BackupedFile> {
|
): Promise<BackupedFile> {
|
||||||
try {
|
try {
|
||||||
if (isDataStream(file.file.encryptedData)) {
|
if (isDataStream(file.file.encryptedData)) {
|
||||||
const { chunkCount, stream } = file.file.encryptedData;
|
const { chunkCount, stream } = file.file.encryptedData;
|
||||||
// const fileKey = await worker.decryptB64(
|
|
||||||
// enFilekey.encryptedData,
|
|
||||||
// enFilekey.nonce,
|
|
||||||
// collectionKey
|
|
||||||
// );
|
|
||||||
// const resp = await new Response(await stream).arrayBuffer();
|
|
||||||
// const decryptedFile: any = await worker.decryptFile(
|
|
||||||
// new Uint8Array(resp),
|
|
||||||
// await worker.fromB64(file.file.decryptionHeader),
|
|
||||||
// fileKey
|
|
||||||
// );
|
|
||||||
// console.log(decryptedFile);
|
|
||||||
// let decryptedFileBlob = new Blob([decryptedFile]);
|
|
||||||
// console.log(URL.createObjectURL(decryptedFileBlob));
|
|
||||||
// return;
|
|
||||||
const filePartUploadURLs = await this.fetchMultipartUploadURLs(
|
const filePartUploadURLs = await this.fetchMultipartUploadURLs(
|
||||||
token,
|
token,
|
||||||
Math.ceil(chunkCount / 2)
|
Math.ceil(chunkCount / 2)
|
||||||
|
|
Loading…
Reference in a new issue