Skip to content

Commit 1449c8a

Browse files
committed
Do not match greedy
1 parent 944bfd8 commit 1449c8a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

debug_toolbar/panels/sql.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ def process(self, stack, stream):
225225

226226

227227
def swap_fields(sql):
228-
return re.sub('SELECT</strong> (.*) <strong>FROM', 'SELECT</strong> <a class="djDebugUncollapsed djDebugToggle" href="#">&bull;&bull;&bull;</a> ' +
228+
return re.sub('SELECT</strong> (.*?) <strong>FROM', 'SELECT</strong> <a class="djDebugUncollapsed djDebugToggle" href="#">&bull;&bull;&bull;</a> ' +
229229
'<a class="djDebugCollapsed djDebugToggle" href="#">\g<1></a> <strong>FROM', sql)
230230

231231

0 commit comments

Comments
 (0)