Skip to content

Commit 2d21af1

Browse files
authored
Merge pull request #1074 from jdufresne/local-current
Make JS varaible "current" local to the event handler
2 parents 6647708 + 9b74a15 commit 2d21af1

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

debug_toolbar/static/debug_toolbar/js/toolbar.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,11 @@
77
isReady: false,
88
init: function() {
99
$('#djDebug').show();
10-
var current = null;
1110
$('#djDebugPanelList').on('click', 'li a', function() {
1211
if (!this.className) {
1312
return false;
1413
}
15-
current = $('#djDebug #' + this.className);
14+
var current = $('#djDebug #' + this.className);
1615
if (current.is(':visible')) {
1716
$(document).trigger('close.djDebug');
1817
$(this).parent().removeClass('djdt-active');

0 commit comments

Comments
 (0)