From c81508dc4306fa9ddc4bbea14a9edcf979536ff9 Mon Sep 17 00:00:00 2001 From: Andrew Nacin Date: Sat, 9 Nov 2013 21:21:10 +0000 Subject: [PATCH] Avoid JSHint errors. Use dot notation when able and declare pwsL10n as a global. props jorbin. fixes #25870. Built from https://develop.svn.wordpress.org/trunk@26065 git-svn-id: http://core.svn.wordpress.org/trunk@25986 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/js/about.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/wp-admin/js/about.js b/wp-admin/js/about.js index 3aaa66d7ae..984b92ffec 100644 --- a/wp-admin/js/about.js +++ b/wp-admin/js/about.js @@ -1,3 +1,4 @@ +/* global pwsL10n:true */ (function($){ var password = 'Gosh, WordPress is grand.', $input = $('#pass'), @@ -19,13 +20,13 @@ $('#pass-strength-result').removeClass('short bad good strong'); switch ( strength ) { case 2: - $('#pass-strength-result').addClass('bad').html( pwsL10n['bad'] ); + $('#pass-strength-result').addClass('bad').html( pwsL10n.bad ); break; case 3: - $('#pass-strength-result').addClass('good').html( pwsL10n['good'] ); + $('#pass-strength-result').addClass('good').html( pwsL10n.good ); break; case 4: - $('#pass-strength-result').addClass('strong').html( pwsL10n['strong'] ); + $('#pass-strength-result').addClass('strong').html( pwsL10n.strong ); break; default: $('#pass-strength-result').addClass('short').html( pwsL10n['short'] );