From 16716551bda6b088fcd41d7d12a782b758e8dcb7 Mon Sep 17 00:00:00 2001 From: Jon Dufresne Date: Mon, 18 May 2020 07:37:05 +0200 Subject: [PATCH] [3.1.x] Refs #31034 -- Used === in nav_sidebar.js admin JS to avoid possible coercion issues. Backport of e46f700e39cef3856f34b56dc5d563d3e27648ac from master --- django/contrib/admin/static/admin/js/nav_sidebar.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/django/contrib/admin/static/admin/js/nav_sidebar.js b/django/contrib/admin/static/admin/js/nav_sidebar.js index 9b558ca2e71..70685f2c066 100644 --- a/django/contrib/admin/static/admin/js/nav_sidebar.js +++ b/django/contrib/admin/static/admin/js/nav_sidebar.js @@ -10,7 +10,7 @@ main.classList.toggle('shifted', navSidebarIsOpen === 'true'); toggleNavSidebar.addEventListener('click', function() { - if (navSidebarIsOpen == 'true') { + if (navSidebarIsOpen === 'true') { navSidebarIsOpen = 'false'; } else { navSidebarIsOpen = 'true';