Commit a64f2b94 authored by Henning Leutz's avatar Henning Leutz 🥋

fix: TypeError: Cannot read property 'getId' of undefined - happens sometimes during file deletion

parent cd0b61fe
......@@ -1171,7 +1171,7 @@ define('controls/projects/project/media/Panel', [
if (!files.length) {
return;
}
console.log('$viewOnDrop');
console.log('$viewOnDrop');
if (Elm.hasClass('qui-media-content')) {
this.$PanelContextMenu.showDragDropMenu(files, Elm, event);
return;
......@@ -2328,10 +2328,14 @@ console.log('$viewOnDrop');
}
if (typeOf(Item) === 'string' || typeOf(Item) === 'number') {
var self = this;
Media.get(Item).then(function (File) {
self.$itemEvent(Media, File);
});
this.$itemEvent(Media, File);
}.bind(this));
return;
}
if (!Item) {
return;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment