Skip to content

Commit 244b416

Browse files
author
Stefano Fadda
committed
Fix file uploads error
1 parent bbaa9e1 commit 244b416

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

js/plainwebrtc.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,11 @@ function fileChannel(e){
147147
}
148148
}else if(type == "[object String]"){
149149
data = JSON.parse(e.data);
150+
}else if(type == "[object Blob]"){
151+
data = e.data;
152+
file_download.href=URL.createObjectURL(data);
153+
file_download.innerHTML="download";
154+
file_download.download = recFileDom.name;
150155
}
151156

152157
// Handle initial msg exchange

0 commit comments

Comments
 (0)