Skip to content

Commit 4fd3757

Browse files
authored
fix(File): accept Blob (#501)
1 parent 3585367 commit 4fd3757

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/file.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ module.exports = function(AV) {
116116
}
117117
}
118118

119-
if (typeof File !== "undefined" && data instanceof File) {
119+
if (typeof Blob !== "undefined" && data instanceof Blob) {
120120
if (data.size) {
121121
this.attributes.metaData.size = data.size;
122122
}
@@ -478,7 +478,7 @@ module.exports = function(AV) {
478478
}
479479
return data.blob;
480480
}
481-
if (typeof File !== "undefined" && data instanceof File) {
481+
if (typeof Blob !== "undefined" && data instanceof Blob) {
482482
return data;
483483
}
484484
if (!process.env.CLIENT_PLATFORM) {

0 commit comments

Comments
 (0)