Skip to content

Commit

Permalink
renamed variable
Browse files Browse the repository at this point in the history
  • Loading branch information
Hidanio committed Jan 30, 2025
1 parent a06619e commit 70a25da
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/linter/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -1580,16 +1580,16 @@ func IsRuleEnabledForPath(root *RuleNode, filePath string, checkRule string) boo
// the path ended - all remaining directories were swallowed
return ruleState
}
testPart := parts[i]
AfterStarPart := parts[i]

// if starNode have Children[testPart] (except "*"),
// if starNode have Children[AfterStarPart] (except "*"),
// so we found the next "literal" node, we exit the inner loop,
// to go through the usual logic at the top level.
if testPart == "" {
if AfterStarPart == "" {
continue
}

_, hasLiteral := currentNode.Children[testPart]
_, hasLiteral := currentNode.Children[AfterStarPart]
if hasLiteral {
// Let's exit - let the outer loop handle it
break
Expand Down

0 comments on commit 70a25da

Please sign in to comment.