Skip to content

Commit

Permalink
Fix inserting excerpt on compare diff (#11833)
Browse files Browse the repository at this point in the history
* Fix inserting excerpt on compare diff

* use currentTarget

* remove comment

Co-authored-by: techknowlogick <techknowlogick@gitea.io>
  • Loading branch information
CirnoT and techknowlogick authored Jun 10, 2020
1 parent 2b2b3e4 commit 42752f3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion web_src/js/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2034,7 +2034,7 @@ function initCodeView() {
box.dataset.folded = String(folded);
});
function insertBlobExcerpt(e) {
const $blob = $(e.target);
const $blob = $(e.currentTarget);
const $row = $blob.parent().parent();
$.get(`${$blob.data('url')}?${$blob.data('query')}&anchor=${$blob.data('anchor')}`, (blob) => {
$row.replaceWith(blob);
Expand Down

0 comments on commit 42752f3

Please sign in to comment.