From f07a0842f0016c4bd1596423346d38f462590b6b Mon Sep 17 00:00:00 2001 From: Marc Delisle Date: Wed, 2 Mar 2011 13:03:24 -0500 Subject: [PATCH] Cache jQuery object to avoid unneeded DOM traversal --- js/server_privileges.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/js/server_privileges.js b/js/server_privileges.js index 816006685..332ad6b85 100644 --- a/js/server_privileges.js +++ b/js/server_privileges.js @@ -193,9 +193,9 @@ $(document).ready(function() { .after(data.sql_query); //Remove the empty notice div generated due to a NULL query passed to PMA_showMessage() - var notice_class = $("#topmenucontainer").next("div").find('.notice'); - if($(notice_class).text() == '') { - $(notice_class).remove(); + var $notice_class = $("#topmenucontainer").next("div").find('.notice'); + if($notice_class.text() == '') { + $notice_class.remove(); } appendNewUser(data.new_user_string, data.new_user_initial, data.new_user_initial_string);