Skip to content

Commit a78fc2f

Browse files
perf(2020-day-07): remove unnecessary check
1 parent 920ff55 commit a78fc2f

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

2020/day-7/bagRules.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,9 @@ const findAllowedOuter = (rules, color) => {
2626

2727
// Loop through the rules, find all colors this bag is allowed within
2828
rules.filter((rule) => {
29-
// console.debug(rule)
3029
if (!rule.inner) { return false }
3130
// match when inners contain the color
3231
return (
33-
rule.inner &&
3432
rule.inner.filter((child) => {
3533
return (child.color === color)
3634
}).length > 0

0 commit comments

Comments
 (0)