From d7848c11e008ddeb036a95d389caa3b2c97b795e Mon Sep 17 00:00:00 2001 From: Tim Graham Date: Mon, 20 Jul 2015 11:42:25 -0400 Subject: [PATCH] Fixed #25147 -- Fixed debug view copy-paste/interactive toggle. The whitespace added in 1101467ce0756272a54f4c7bc65c4c335a94111b broke the initial comparison. --- django/views/debug.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/django/views/debug.py b/django/views/debug.py index d85d385e019..e7f2bbd6b28 100644 --- a/django/views/debug.py +++ b/django/views/debug.py @@ -646,7 +646,7 @@ TECHNICAL_500_TEMPLATE = (""" function switchPastebinFriendly(link) { s1 = "Switch to copy-and-paste view"; s2 = "Switch back to interactive view"; - link.innerHTML = link.innerHTML == s1 ? s2: s1; + link.innerHTML = link.innerHTML.trim() == s1 ? s2: s1; toggle('browserTraceback', 'pastebinTraceback'); return false; }