Fix card & file drop issues

Signed-off-by: Anna No <anna.no@xored.com>
This commit is contained in:
Anna No 2022-04-13 21:16:49 +07:00
parent 95ea34d27a
commit c5f7d6d1e9
No known key found for this signature in database
GPG Key ID: 08C11FFC23177C87

View File

@ -36,14 +36,15 @@
return
}
e.preventDefault()
e.stopPropagation()
const list = e.dataTransfer?.files
if (list === undefined || list.length === 0) return
loading++
try {
await createAttachments(client, list, { objectClass, objectId, space })
e.preventDefault()
e.stopPropagation()
} finally {
loading--
}