diff options
author | Mario <mario@mariovavti.com> | 2021-06-29 09:53:40 +0000 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2021-06-29 09:53:40 +0000 |
commit | 197d15b7de34c670934cfe873e7c67233e090009 (patch) | |
tree | 5ca4b4f2bc426747cc22ab2d6c52720aedbd91ce /view | |
parent | bb5f6a1d79217222363bf803125278b05049d2b6 (diff) | |
download | volse-hubzilla-197d15b7de34c670934cfe873e7c67233e090009.tar.gz volse-hubzilla-197d15b7de34c670934cfe873e7c67233e090009.tar.bz2 volse-hubzilla-197d15b7de34c670934cfe873e7c67233e090009.zip |
only remove elements after the delete has happened
Diffstat (limited to 'view')
-rw-r--r-- | view/js/main.js | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/view/js/main.js b/view/js/main.js index 9ef81b72c..f427df8ad 100644 --- a/view/js/main.js +++ b/view/js/main.js @@ -1284,18 +1284,18 @@ function dropItem(url, object, b64mid) { $.get(url, function() { $(object + ', #pinned-wrapper-' + id).remove(); $('body').css('cursor', 'auto'); + + if (typeof b64mid !== typeof undefined) { + $('[data-b64mid=\'' + b64mid + '\']').fadeOut(function() { + this.remove(); + }); + } }); if($('#wall-item-pinned-' + id).length) { $.post('pin/pin', { 'id' : id }); } - if (typeof b64mid !== typeof undefined) { - $('[data-b64mid=\'' + b64mid + '\']').fadeOut(function() { - this.remove(); - }); - } - return true; } else { |