aboutsummaryrefslogtreecommitdiff
path: root/javascript/dragdrop.js
diff options
context:
space:
mode:
authorAUTOMATIC <16777216c@gmail.com>2023-05-22 15:40:10 +0300
committerAUTOMATIC <16777216c@gmail.com>2023-05-22 15:40:10 +0300
commitcc2f6e3b7b8d720a8e0fb2732751e34b7f41c2e9 (patch)
tree9a864851359e5fd56d36c8e30d3df5c42d5fb28d /javascript/dragdrop.js
parentee65e729319e4184fc0d49552657e98aa0e28f17 (diff)
fix error in dragdrop logic
Diffstat (limited to 'javascript/dragdrop.js')
-rw-r--r--javascript/dragdrop.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/javascript/dragdrop.js b/javascript/dragdrop.js
index aa79871a..5803daea 100644
--- a/javascript/dragdrop.js
+++ b/javascript/dragdrop.js
@@ -57,8 +57,8 @@ function eventHasFiles(e) {
}
function dragDropTargetIsPrompt(target) {
- if (!(target?.placeholder?.indexOf("Prompt") >= 0)) return true;
- if (target?.parentNode?.parentNode) return true;
+ if (target?.placeholder && target?.placeholder.indexOf("Prompt") >= 0) return true;
+ if (target?.parentNode?.parentNode?.className?.indexOf("prompt") > 0) return true;
return false;
}