Skip to content
This repository was archived by the owner on Feb 1, 2022. It is now read-only.

Commit 6eb502e

Browse files
author
Zac Echola
committed
simplify selector
1 parent 6e7f518 commit 6eb502e

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/bootlint.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -409,9 +409,7 @@ var LocationIndex = _location.LocationIndex;
409409
}
410410
});
411411
addLinter("E004", function lintNestedContainers($, reporter) {
412-
var nestedContainers = $('.container, .container-fluid').filter(function () {
413-
return $(this).find('.navbar').length === 0;
414-
}).find('.container, .container-fluid');
412+
var nestedContainers = $('.container, .container-fluid').not(':has(.navbar)').find('.container, .container-fluid');
415413
if (nestedContainers.length) {
416414
reporter("Containers (`.container` and `.container-fluid`) are not nestable", nestedContainers);
417415
}

0 commit comments

Comments
 (0)