fix: Dragging strings into document can attempt (and file) to insert as attachment

This commit is contained in:
Tom Moor committed 2022-03-06 21:47:30 -08:00
1 parent 631d600920
commit cf446be2df
1 file changed
+3 -1
+3 -1
View File
@@ -74,7 +74,9 @@ const uploadPlugin = (options: Options) =>
}
// filter to only include image files
const files = getDataTransferFiles(event);
const files = getDataTransferFiles(event).filter(
(dt: any) => dt.kind !== "string"
);
if (files.length === 0) {
return false;
}