murphy
09/18/2021, 8:54 PMmurphy
09/18/2021, 9:08 PMfetch
API to build a File
object from a data URL. The File object has a byte size of 1433680. I then use supabase to upload it:murphy
09/18/2021, 9:08 PMdebug(`Made a File object with size ${encryptedFile.size}`);
debug(`Attempting upload to supabase storage`);
var { error: mediaError } = await supabase.storage
.from("media")
.upload(mediaPath, encryptedFile);
if (mediaError) {
fail(`Failed while uploading media ${JSON.stringify(mediaError)}`);
}
debug(`Finished uploading media file`);
murphy
09/18/2021, 9:09 PMmurphy
09/18/2021, 9:10 PMmurphy
09/18/2021, 9:13 PMmurphy
09/18/2021, 10:06 PMJaeden
11/22/2021, 5:01 PMmurphy
11/22/2021, 5:06 PMmurphy
11/22/2021, 5:07 PMJaeden
11/22/2021, 5:07 PMJaeden
11/22/2021, 5:07 PMJaeden
11/22/2021, 5:08 PMArrayBuffer { 18:00:20
[Uint8Contents]: <75 ab 5a 02 29 9a 81 ef e9 9e 00 1b 6a c7 ba e0 08 95 04 e4 70 d0 a1 a0 a0 00 00 00 d4 94 84 45 20 00 00 64 00 00 00 32 00 80 60 00 00 07 bc 0a e5 a0 00 00 00 17 35 24 74 20 0a ec e1 ce 90 00 02 00 04 94 44 15 47 89 ce cb dc fc f7 6d b9 11 d5 4e 7d ad d6 e0 7a bb b1 12 45 6e 80 40 15 18 46 c8 14 49 ... 346371 more bytes>,
byteLength: 346471
}