summaryrefslogtreecommitdiffstats
path: root/web/react/components/file_upload.jsx
diff options
context:
space:
mode:
Diffstat (limited to 'web/react/components/file_upload.jsx')
-rw-r--r--web/react/components/file_upload.jsx7
1 files changed, 3 insertions, 4 deletions
diff --git a/web/react/components/file_upload.jsx b/web/react/components/file_upload.jsx
index f1a06c361..2bce1b537 100644
--- a/web/react/components/file_upload.jsx
+++ b/web/react/components/file_upload.jsx
@@ -91,9 +91,6 @@ module.exports = React.createClass({
this.props.onUploadError(null);
var files = e.originalEvent.dataTransfer.files;
- if (!files.length) {
- files = e.originalEvent.dataTransfer.getData('URL');
- }
var channelId = this.props.channelId || ChannelStore.getCurrentId();
if (typeof files !== 'string' && files.length) {
@@ -142,6 +139,8 @@ module.exports = React.createClass({
this.props.onUploadStart([clientId], channelId);
}
+ } else {
+ this.props.onUploadError('Invalid file upload', -1);
}
},
componentDidMount: function() {
@@ -149,7 +148,7 @@ module.exports = React.createClass({
var self = this;
if (this.props.postType === 'post') {
- $('.app__content').dragster({
+ $('.row.main').dragster({
enter: function(dragsterEvent, e) {
$('.center-file-overlay').removeClass('invisible');
$('.center-file-overlay').addClass('visible');