Follow-up of #1664940: [Policy, patch] Decide on JSHint configuration and part of #1415788: Javascript winter clean-up

Run jshint on the files with the configuration from the parent issue or use jshint.com with the following options:

/*jshint forin:true, noarg:true, eqeqeq:true, undef:true, curly:true, browser:true, expr:true, latedef:true, newcap:true, trailing:true */
/*global Drupal, jQuery */

Fix any warnings or errors the tool finds.
Check manually that the fixes did not break any functionalities
Create patch and upload for the testbot.

Files: simpletest/simpletest.js

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

nod_’s picture

core/modules/simpletest/simpletest.js: line 79, col 12, Don't make functions within a loop.
core/modules/simpletest/simpletest.js: line 96, col 10, Don't make functions within a loop.
nod_’s picture

Status: Active » Needs review
FileSize
1.49 KB

works for me

droplet’s picture

Status: Needs review » Needs work
+++ b/core/modules/simpletest/simpletest.jsundefined
@@ -69,17 +69,15 @@ Drupal.behaviors.simpleTestSelectAll = {
+          if ($('#' + testCheckboxes[i]).attr('checked')) {

might be use prop() ?

nod_’s picture

Status: Needs work » Needs review
FileSize
1.81 KB

Yep you're right. put prop everywhere to keep it consistent. Still works fine.

droplet’s picture

Status: Needs review » Reviewed & tested by the community
Dries’s picture

Status: Reviewed & tested by the community » Fixed

Committed to 8.x. Thanks.

Automatically closed -- issue fixed for 2 weeks with no activity.