access control

This commit is contained in:
Eddie Wang 2019-12-03 16:28:05 -05:00
parent 4bfcde3ed7
commit ae761c8d85
No known key found for this signature in database
GPG Key ID: DBFB3E83121BEDD1
1 changed files with 4 additions and 1 deletions

View File

@ -16,7 +16,10 @@ function MyDropzone() {
const url = API_ENDPOINT + "/siafile"
fetch(url, {
method: "POST",
body: fd
body: fd,
headers: {
"Access-Control-Allow-Origin": "*"
}
}).then(res => {
const readableStream = res.body
const fileStream = streamSaver.createWriteStream("file.webm")