Skip to content

Commit

Permalink
Fix sql-duplicate highlight (#1699)
Browse files Browse the repository at this point in the history
  • Loading branch information
erikn69 authored Nov 1, 2024
1 parent 5fa66aa commit 295bb30
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/Resources/queries/widget.js
Original file line number Diff line number Diff line change
Expand Up @@ -229,9 +229,11 @@
.attr('data-duplicate', false)
.append($('<strong />').addClass(csscls('sql name')).text(statement.sql));
} else {
const $code = $('<code />').html(PhpDebugBar.Widgets.highlight(statement.sql, 'sql')).addClass(csscls('sql'));
const $code = $('<code />').html(PhpDebugBar.Widgets.highlight(statement.sql, 'sql')).addClass(csscls('sql')),
duplicated = this.duplicateQueries.has(statement);
$li.attr('data-connection', statement.connection)
.attr('data-duplicate', this.duplicateQueries.has(statement))
.attr('data-duplicate', duplicated)
.toggleClass(csscls('sql-duplicate'), duplicated)
.append($code);

if (statement.show_copy) {
Expand Down

0 comments on commit 295bb30

Please sign in to comment.