Skip to content

Commit

Permalink
Prevent query backtrace showing on editor link click (#667)
Browse files Browse the repository at this point in the history
  • Loading branch information
erikn69 authored Sep 6, 2024
1 parent 643767a commit ec49790
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/DebugBar/Resources/widgets/sqlqueries/widget.js
Original file line number Diff line number Diff line change
Expand Up @@ -128,13 +128,13 @@
}
if (typeof(stmt.xdebug_link) !== 'undefined' && stmt.xdebug_link) {
var header = $('<span title="Filename" />').addClass(csscls('filename')).text(stmt.xdebug_link.filename + ( stmt.xdebug_link.line ? "#" + stmt.xdebug_link.line : ''));
if (stmt.xdebug_link.ajax) {
$('<a title="' + stmt.xdebug_link.url + '"></a>').on('click', function () {
$('<a href="' + stmt.xdebug_link.url + '"></a>').on('click', function () {
event.stopPropagation();
if (stmt.xdebug_link.ajax) {
fetch(stmt.xdebug_link.url);
}).addClass(csscls('editor-link')).appendTo(header);
} else {
$('<a href="' + stmt.xdebug_link.url + '"></a>').addClass(csscls('editor-link')).appendTo(header);
}
event.preventDefault();
}
}).addClass(csscls('editor-link')).appendTo(header);
header.appendTo(li);
}
var table = $('<table></table>').addClass(csscls('params'));
Expand Down

0 comments on commit ec49790

Please sign in to comment.